apiVersion: shipwright.io/v1beta1
kind: ClusterBuildStrategy
metadata:
name: buildah-small
spec:
steps:
- name: build-and-push
image: quay.io/containers/buildah:v1.31.0
workingDir: $(params.shp-source-root)
securityContext:
capabilities:
add:
- "SETFCAP"
command:
- /bin/bash
args:
- -c
- |
set -euo pipefail
# Parse parameters
# ...
# That's the separator between the shell script and its args
- --
- --context
- $(params.shp-source-context)
- --dockerfile
- $(build.dockerfile)
- --image
- $(params.shp-output-image)
- --build-args
- $(params.build-args[*])
- --registries-block
- $(params.registries-block[*])
- --registries-insecure
- $(params.registries-insecure[*])
- --registries-search
- $(params.registries-search[*])
resources:
limits:
cpu: 250m
memory: 65Mi
requests:
cpu: 250m
memory: 65Mi
parameters:
- name: build-args
description: "The values for the args in the Dockerfile. Values must be in the format KEY=VALUE."
type: array
defaults: []
# ...
apiVersion: shipwright.io/v1beta1
kind: ClusterBuildStrategy
metadata:
name: buildah-small
spec:
steps:
- name: build-and-push
image: quay.io/containers/buildah:v1.31.0
workingDir: $(params.shp-source-root)
securityContext:
capabilities:
add:
- "SETFCAP"
command:
- /bin/bash
args:
- -c
- |
set -euo pipefail
# Parse parameters
- --
- --context
- $(params.shp-source-context)
- --dockerfile
- $(build.dockerfile)
- --image
- $(params.shp-output-image)
- --build-args
- $(params.build-args[*])
- --registries-block
- $(params.registries-block[*])
- --registries-insecure
- $(params.registries-insecure[*])
- --registries-search
- $(params.registries-search[*])
resources:
limits:
cpu: 250m
memory: 65Mi
requests:
cpu: 250m
memory: 65Mi
parameters:
- name: build-args
description: "The values for the args in the Dockerfile. Values must be in the format KEY=VALUE."
type: array
defaults: []
Copy to Clipboard
Copied!
Toggle word wrap
Toggle overflow