modified: .gitea/limbo_actions/buildkit-build-push/action.yaml
/ build-docker-image (push) Failing after 13s
/ build-docker-image (push) Failing after 13s
This commit is contained in:
@@ -35,13 +35,32 @@ inputs:
|
|||||||
runs:
|
runs:
|
||||||
using: "composite"
|
using: "composite"
|
||||||
steps:
|
steps:
|
||||||
|
- name: run buildctl build and push
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
- name: run buildctl build and push
|
- name: run buildctl build and push
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
|
|
||||||
AUTH=$(printf '{"username":"%s","password":"%s"}' \
|
# create docker config temp folder
|
||||||
"${{ inputs.registry_username }}" \
|
DOCKER_CONFIG_DIR="${RUNNER_TEMP}/.buildctl_docker"
|
||||||
"${{ inputs.registry_password }}" | base64 -w0)
|
mkdir -p "$DOCKER_CONFIG_DIR"
|
||||||
|
|
||||||
|
# clean up
|
||||||
|
trap 'rm -rf "$DOCKER_CONFIG_DIR"' EXIT
|
||||||
|
|
||||||
|
# setup file docker config (auth) temp file
|
||||||
|
AUTH=$(printf "%s" "${{ inputs.registry_username }}:${{ inputs.registry_password }}" | base64 -w 0)
|
||||||
|
|
||||||
|
cat > "$DOCKER_CONFIG_DIR/config.json" <<EOF
|
||||||
|
{
|
||||||
|
"auths": {
|
||||||
|
"${{ inputs.registry_addr }}": {
|
||||||
|
"auth": "$AUTH"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
|
||||||
# Build build-arg flags
|
# Build build-arg flags
|
||||||
BUILD_ARG_FLAGS=""
|
BUILD_ARG_FLAGS=""
|
||||||
@@ -52,7 +71,7 @@ runs:
|
|||||||
|
|
||||||
echo "Using build args: $BUILD_ARG_FLAGS"
|
echo "Using build args: $BUILD_ARG_FLAGS"
|
||||||
|
|
||||||
buildctl \
|
DOCKER_CONFIG=$DOCKER_CONFIG_DIR buildctl \
|
||||||
--addr ${{ inputs.buildkit_addr }} \
|
--addr ${{ inputs.buildkit_addr }} \
|
||||||
build \
|
build \
|
||||||
--frontend=dockerfile.v0 \
|
--frontend=dockerfile.v0 \
|
||||||
|
|||||||
Reference in New Issue
Block a user