Skip to content

Commit

Permalink
fix ci files
Browse files Browse the repository at this point in the history
  • Loading branch information
dfry committed May 19, 2023
1 parent 7f154fc commit fae03ff
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion terraform/gitlab/ci-templates/bootstrap/.gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,8 @@ prepare:image:
DOCKER_TAG: latest
before_script:
# Authenticate to the docker registry and dependency proxy
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"auth\":\"$(printf "%s:%s" "${CI_REGISTRY_USER}" "${CI_REGISTRY_PASSWORD}" | base64 | tr -d '\n')\"},\"ghcr.io\":{\"auth\":\"$(printf "%s:%s" "${PRIVATE_REPO_USER}" "${PRIVATE_REPO_TOKEN}" | base64 | tr -d '\n')\"}}}" > /kaniko/.docker/config.json
- if [ "$PRIVATE_REPO_USER" == "nullvalue" ]; then export PRIVATE_REPO_HOST=null.com; else export PRIVATE_REPO_HOST=ghcr.io; fi
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"auth\":\"$(printf "%s:%s" "${CI_REGISTRY_USER}" "${CI_REGISTRY_PASSWORD}" | base64 | tr -d '\n')\"},\"${PRIVATE_REPO_HOST}\":{\"auth\":\"$(printf "%s:%s" "${PRIVATE_REPO_USER}" "${PRIVATE_REPO_TOKEN}" | base64 | tr -d '\n')\"}}}" > /kaniko/.docker/config.json
script:
- /kaniko/executor
--context "${CI_PROJECT_DIR}/.gitlab/ci"
Expand Down
3 changes: 2 additions & 1 deletion terraform/gitlab/ci-templates/k8s-cluster/.gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,8 @@ prepare:image:
DOCKER_TAG: latest
before_script:
# Authenticate to the docker registry and dependency proxy
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"auth\":\"$(printf "%s:%s" "${CI_REGISTRY_USER}" "${CI_REGISTRY_PASSWORD}" | base64 | tr -d '\n')\"},\"ghcr.io\":{\"auth\":\"$(printf "%s:%s" "${PRIVATE_REPO_USER}" "${PRIVATE_REPO_TOKEN}" | base64 | tr -d '\n')\"}}}" > /kaniko/.docker/config.json
- if [ "$PRIVATE_REPO_USER" == "nullvalue" ]; then export PRIVATE_REPO_HOST=null.com; else export PRIVATE_REPO_HOST=ghcr.io; fi
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"auth\":\"$(printf "%s:%s" "${CI_REGISTRY_USER}" "${CI_REGISTRY_PASSWORD}" | base64 | tr -d '\n')\"},\"${PRIVATE_REPO_HOST}\":{\"auth\":\"$(printf "%s:%s" "${PRIVATE_REPO_USER}" "${PRIVATE_REPO_TOKEN}" | base64 | tr -d '\n')\"}}}" > /kaniko/.docker/config.json
script:
- /kaniko/executor
--context "${CI_PROJECT_DIR}/.gitlab/ci"
Expand Down

0 comments on commit fae03ff

Please sign in to comment.