Skip to content

Commit

Permalink
feat(ci): use regproxy during ci
Browse files Browse the repository at this point in the history
to fix TOOMANYREQUESTS pulling base image
  • Loading branch information
ChandonPierre committed Sep 11, 2023
1 parent 60346d7 commit e3d3240
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@ build:
REF_IMAGE: $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG
FIXED_IMAGE: $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA
DOCKERFILE: ${CI_PROJECT_DIR}/Dockerfile
REGPROXY_URI: ${REGPROXY_URI}
before_script:
- export HTTP_PROXY=${CACHE_PROXY}
- export NO_PROXY=${CACHE_REGISTRY_HOST}
- export HTTP_PROXY=${REGPROXY_URI}
- export HTTPS_PROXY=${REGPROXY_URI}
- mkdir -p /etc/ssl/certs/ && cat /etc/gitlab-runner/certs/proxy-ca.crt >> /etc/ssl/certs/ca-certificates.crt
- mkdir -p /kaniko/.docker
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
script: |-
Expand Down

0 comments on commit e3d3240

Please sign in to comment.