CI/CircleCI: Authenticate to DockerHub when pulling the docker image (#25581)

For more information see the following links:
- https://www.docker.com/blog/scaling-docker-to-serve-millions-more-developers-network-egress/
- https://docs.docker.com/docker-hub/download-rate-limit/
- https://circleci.com/docs/2.0/private-images/

Add DOCKERHUB_USERNAME and DOCKERHUB_PASSWORD secrets to CircleCI Environment Variables. DOCKERHUB_PASSWORD can be either the password or an access token.

(cherry picked from commit e3da1ed245)
This commit is contained in:
Giacomo Pozzoni
2020-10-17 14:24:54 +02:00
committed by Shauren
parent 01a11ac27c
commit a7473f1a91

View File

@@ -3,7 +3,13 @@ jobs:
codestyle_and_sql:
docker:
- image: trinitycore/circle-ci:master-buildpacks-focal
auth:
username: $DOCKERHUB_USERNAME
password: $DOCKERHUB_PASSWORD
- image: circleci/mysql:8
auth:
username: $DOCKERHUB_USERNAME
password: $DOCKERHUB_PASSWORD
environment:
MYSQL_ALLOW_EMPTY_PASSWORD: yes
MYSQL_ROOT_PASSWORD: ''
@@ -39,6 +45,9 @@ jobs:
pch:
docker:
- image: trinitycore/circle-ci:master-buildpacks-focal
auth:
username: $DOCKERHUB_USERNAME
password: $DOCKERHUB_PASSWORD
steps:
- run:
name: Checkout
@@ -70,6 +79,9 @@ jobs:
nopch:
docker:
- image: trinitycore/circle-ci:master-buildpacks-focal
auth:
username: $DOCKERHUB_USERNAME
password: $DOCKERHUB_PASSWORD
steps:
- run:
name: Requirements