Conversation
Useful to have full control over underlaying tooling, such as docker version. Keep step outputs compatible to "build-push-action". Signed-off-by: Philipp Heil (zkdev) <philipp.heil@sap.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
@ccwienk, @TuanAnh17N, @8R0WNI3 You have pull request review open invite, please check |
| file: ${{ inputs.dockerfile }} | ||
| build-args: ${{ inputs.build-args }} | ||
| run: | | ||
| IFS=',' read -ra TAGS <<< "${{ matrix.args.image-reference }}" |
There was a problem hiding this comment.
codestyle: I think it is preferable to use lowercase names for shell-variables, as uppercased variables are typically intended for global / systemwide exports.
In addition, preferably use single-quotes such as to avoid shell-expansion, where we are dereferencing vaules from gha-inputs
| fi | ||
|
|
||
| docker buildx build \ | ||
| --file ${{ inputs.dockerfile }} \ |
There was a problem hiding this comment.
quote (there might be a whitespace....)
| docker buildx build \ | ||
| --file ${{ inputs.dockerfile }} \ | ||
| --output type=docker \ | ||
| --platform ${{ matrix.args.platform-name }} \ |
There was a problem hiding this comment.
quote. while platform-names will never contain whitespace, errors in args-preprocessing will be easier to detect this way
| --file ${{ inputs.dockerfile }} \ | ||
| --output type=docker \ | ||
| --platform ${{ matrix.args.platform-name }} \ | ||
| --builder ${{ steps.buildx-setup.outputs.name }} \ |
| --platform ${{ matrix.args.platform-name }} \ | ||
| --builder ${{ steps.buildx-setup.outputs.name }} \ | ||
| --metadata-file /tmp/metadata.json \ | ||
| --iidfile /tmp/iidfile \ |
There was a problem hiding this comment.
codestyle: rather call it image_id[_file].
| $TARGET_ARG \ | ||
| $TAG_ARGS \ | ||
| $BUILD_ARGS \ | ||
| ${{ inputs.build-directory }} |
There was a problem hiding this comment.
also, we might want to add a check (prior to running build) for build-directory to be non-empty (we might also check whether it is an existing directory..)
Useful to have full control over underlaying tooling, such as docker version. Keep step outputs compatible to "build-push-action".
Release note: