mirror of
https://github.com/redhat-actions/buildah-build.git
synced 2025-04-20 09:01:23 +00:00
Add configuration to disable storage-overlay config
By disabling this feature buildah defaults to the normal configuration, which in case of running on kernel >5.13 would default to the native overlay. The native overlay is way quicker than fuse-overlayfs and drastically improves build speed.
This commit is contained in:
parent
b4dc19b4ba
commit
0a7492d635
5 changed files with 24 additions and 11 deletions
13
action.yml
13
action.yml
|
@ -9,11 +9,11 @@ inputs:
|
||||||
description: 'The name (reference) of the image to build'
|
description: 'The name (reference) of the image to build'
|
||||||
required: false
|
required: false
|
||||||
tags:
|
tags:
|
||||||
description: 'The tags of the image to build. For multiple tags, seperate by whitespace. For example, "latest v1".'
|
description: 'The tags of the image to build. For multiple tags, separate by whitespace. For example, "latest v1".'
|
||||||
required: false
|
required: false
|
||||||
default: latest
|
default: latest
|
||||||
labels:
|
labels:
|
||||||
description: 'The labels of the image to build. Seperate by newline. For example, "io.containers.capabilities=sys_admin,mknod".'
|
description: 'The labels of the image to build. Separate by newline. For example, "io.containers.capabilities=sys_admin,mknod".'
|
||||||
required: false
|
required: false
|
||||||
base-image:
|
base-image:
|
||||||
description: 'The base image to use to create a new container image'
|
description: 'The base image to use to create a new container image'
|
||||||
|
@ -60,7 +60,7 @@ inputs:
|
||||||
archs:
|
archs:
|
||||||
description: |
|
description: |
|
||||||
'Same as input 'arch', use this for multiple architectures.
|
'Same as input 'arch', use this for multiple architectures.
|
||||||
Seperate them by a comma'
|
Separate them by a comma'
|
||||||
required: false
|
required: false
|
||||||
platform:
|
platform:
|
||||||
description: |
|
description: |
|
||||||
|
@ -70,7 +70,7 @@ inputs:
|
||||||
platforms:
|
platforms:
|
||||||
description: |
|
description: |
|
||||||
'Same as input 'platform', use this for multiple platforms.
|
'Same as input 'platform', use this for multiple platforms.
|
||||||
Seperate them by a comma'
|
Separate them by a comma'
|
||||||
required: false
|
required: false
|
||||||
extra-args:
|
extra-args:
|
||||||
description: |
|
description: |
|
||||||
|
@ -82,6 +82,11 @@ inputs:
|
||||||
Require HTTPS and verify certificates when accessing the registry. Defaults to true.
|
Require HTTPS and verify certificates when accessing the registry. Defaults to true.
|
||||||
required: false
|
required: false
|
||||||
default: 'true'
|
default: 'true'
|
||||||
|
storage-overlay:
|
||||||
|
description: |
|
||||||
|
Configure storage-overlay auto-detection
|
||||||
|
required: false
|
||||||
|
default: 'true'
|
||||||
outputs:
|
outputs:
|
||||||
image:
|
image:
|
||||||
description: 'Name of the image built'
|
description: 'Name of the image built'
|
||||||
|
|
2
dist/index.js
vendored
2
dist/index.js
vendored
File diff suppressed because one or more lines are too long
2
dist/index.js.map
vendored
2
dist/index.js.map
vendored
File diff suppressed because one or more lines are too long
|
@ -8,7 +8,7 @@ export enum Inputs {
|
||||||
ARCH = "arch",
|
ARCH = "arch",
|
||||||
/**
|
/**
|
||||||
* 'Same as input 'arch', use this for multiple architectures.
|
* 'Same as input 'arch', use this for multiple architectures.
|
||||||
* Seperate them by a comma'
|
* Separate them by a comma'
|
||||||
* Required: false
|
* Required: false
|
||||||
* Default: None.
|
* Default: None.
|
||||||
*/
|
*/
|
||||||
|
@ -75,7 +75,7 @@ export enum Inputs {
|
||||||
*/
|
*/
|
||||||
IMAGE = "image",
|
IMAGE = "image",
|
||||||
/**
|
/**
|
||||||
* The labels of the image to build. Seperate by newline. For example, "io.containers.capabilities=sys_admin,mknod".
|
* The labels of the image to build. Separate by newline. For example, "io.containers.capabilities=sys_admin,mknod".
|
||||||
* Required: false
|
* Required: false
|
||||||
* Default: None.
|
* Default: None.
|
||||||
*/
|
*/
|
||||||
|
@ -101,7 +101,7 @@ export enum Inputs {
|
||||||
PLATFORM = "platform",
|
PLATFORM = "platform",
|
||||||
/**
|
/**
|
||||||
* 'Same as input 'platform', use this for multiple platforms.
|
* 'Same as input 'platform', use this for multiple platforms.
|
||||||
* Seperate them by a comma'
|
* Separate them by a comma'
|
||||||
* Required: false
|
* Required: false
|
||||||
* Default: None.
|
* Default: None.
|
||||||
*/
|
*/
|
||||||
|
@ -113,7 +113,13 @@ export enum Inputs {
|
||||||
*/
|
*/
|
||||||
PORT = "port",
|
PORT = "port",
|
||||||
/**
|
/**
|
||||||
* The tags of the image to build. For multiple tags, seperate by whitespace. For example, "latest v1".
|
* Configure storage-overlay auto-detection
|
||||||
|
* Required: false
|
||||||
|
* Default: "true"
|
||||||
|
*/
|
||||||
|
STORAGE_OVERLAY = "storage-overlay",
|
||||||
|
/**
|
||||||
|
* The tags of the image to build. For multiple tags, separate by whitespace. For example, "latest v1".
|
||||||
* Required: false
|
* Required: false
|
||||||
* Default: "latest"
|
* Default: "latest"
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -26,7 +26,9 @@ export async function run(): Promise<void> {
|
||||||
await cli.execute([ "version" ], { group: true });
|
await cli.execute([ "version" ], { group: true });
|
||||||
|
|
||||||
// Check if fuse-overlayfs exists and find the storage driver
|
// Check if fuse-overlayfs exists and find the storage driver
|
||||||
|
if (core.getInput(Inputs.STORAGE_OVERLAY)) {
|
||||||
await cli.setStorageOptsEnv();
|
await cli.setStorageOptsEnv();
|
||||||
|
}
|
||||||
|
|
||||||
const DEFAULT_TAG = "latest";
|
const DEFAULT_TAG = "latest";
|
||||||
const workspace = process.env.GITHUB_WORKSPACE || process.cwd();
|
const workspace = process.env.GITHUB_WORKSPACE || process.cwd();
|
||||||
|
|
Loading…
Reference in a new issue