docker pat to actions secret in gitea side
CI / Load gitea-env.conf to pipeline env (push) Successful in 15s
ci-check Build version 0.1.0 required
ci-docker-build Docker build 0.1.0 OK
ci-docker-push Docker push 0.1.0 OK
ci-docker-tag Tag 0.1.0 OK
CI / Build & Push Artifact (push) Successful in 1m56s
CI / Load gitea-env.conf to pipeline env (push) Successful in 15s
ci-check Build version 0.1.0 required
ci-docker-build Docker build 0.1.0 OK
ci-docker-push Docker push 0.1.0 OK
ci-docker-tag Tag 0.1.0 OK
CI / Build & Push Artifact (push) Successful in 1m56s
This commit is contained in:
@@ -28,7 +28,7 @@ env:
|
||||
GIT_PAGES_PUBLISH_TOKEN: ${{ secrets.GIT_PAGES_PUBLISH_TOKEN }}
|
||||
REPO: ${{ github.repository }}
|
||||
DOCKER_REGISTRY: ${{ fromJson(inputs.env_json).DOCKER_REGISTRY || '' }}
|
||||
DOCKER_IMAGE_TAG: ${{ fromJson(inputs.env_json).DOCKER_IMAGE_TAG || '' }}
|
||||
DOCKER_IMAGE_NAME: ${{ fromJson(inputs.env_json).DOCKER_IMAGE_NAME || '' }}
|
||||
DOCKER_UI_URL: ${{ fromJson(inputs.env_json).DOCKER_UI_URL || '' }}
|
||||
|
||||
concurrency:
|
||||
@@ -153,7 +153,7 @@ jobs:
|
||||
--label "git.commit=${{ github.sha }}" \
|
||||
--label "git.commitBy=${{ github.actor }}" \
|
||||
--label "build.date=${NOW}" \
|
||||
-t "${DOCKER_IMAGE_TAG}:${NEXT_VERSION}" .
|
||||
-t "${DOCKER_IMAGE_NAME}:${NEXT_VERSION}" .
|
||||
|
||||
- name: Report status SUCCESS
|
||||
if: steps.gatekeeper.outputs.skip == 'false' && success()
|
||||
@@ -172,7 +172,7 @@ jobs:
|
||||
run: |
|
||||
source /tmp/build-ctx/build.env
|
||||
mkdir -p /tmp/image
|
||||
docker save "${DOCKER_IMAGE_TAG}:${NEXT_VERSION}" -o /tmp/image/artifact.tar
|
||||
docker save "${DOCKER_IMAGE_NAME}:${NEXT_VERSION}" -o /tmp/image/artifact.tar
|
||||
|
||||
- name: Upload Docker image artifact
|
||||
if: steps.gatekeeper.outputs.skip == 'false' && success()
|
||||
@@ -232,13 +232,13 @@ jobs:
|
||||
docker load -i /tmp/image/artifact.tar
|
||||
|
||||
REGISTRY="${DOCKER_REGISTRY:?DOCKER_REGISTRY not set in env.conf}"
|
||||
IMAGE="${DOCKER_IMAGE_TAG:?DOCKER_IMAGE_TAG not set in env.conf}"
|
||||
IMAGE="${DOCKER_IMAGE_NAME:?DOCKER_IMAGE_NAME not set in env.conf}"
|
||||
REGISTRY_HOST="${REGISTRY%%/*}"
|
||||
|
||||
FULL_IMAGE="${REGISTRY}/${IMAGE}:${NEXT_VERSION}"
|
||||
echo "Pushing ${FULL_IMAGE} ..."
|
||||
|
||||
docker tag "${DOCKER_IMAGE_TAG}:${NEXT_VERSION}" "$FULL_IMAGE"
|
||||
docker tag "${DOCKER_IMAGE_NAME}:${NEXT_VERSION}" "$FULL_IMAGE"
|
||||
echo "$DOCKER_PASSWORD" | docker login "$REGISTRY_HOST" -u "$DOCKER_USERNAME" --password-stdin
|
||||
docker push "$FULL_IMAGE"
|
||||
docker logout "$REGISTRY_HOST"
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
GITEA_API_URL=https://gitea.app.keskikuja.site
|
||||
GIT_PAGES_URL=https://ci-reports.helm-dev.keskikuja.site
|
||||
DOCKER_REGISTRY=gitea.app.keskikuja.site/niko
|
||||
DOCKER_IMAGE_TAG=gitea-ci-library-test-image
|
||||
DOCKER_IMAGE_NAME=gitea-ci-library-test-image
|
||||
DOCKER_UI_URL=https://gitea.app.keskikuja.site/niko/gitea-ci-library/packages
|
||||
|
||||
Reference in New Issue
Block a user