Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Update circleci to use docker auth #855

Merged
merged 3 commits into from
Oct 12, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ jobs:
checks:
docker:
- image: circleci/rust:latest
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
steps:
- checkout
- setup-rust
Expand All @@ -124,12 +127,18 @@ jobs:
build-and-test:
docker:
- image: circleci/rust:latest
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
environment:
SYNC_DATABASE_URL: mysql://test:[email protected]/syncstorage
RUST_BACKTRACE: 1
# XXX: begin_test_transaction doesn't play nice over threaded tests
RUST_TEST_THREADS: 1
- image: circleci/mysql:5.7-ram
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
environment:
MYSQL_ROOT_PASSWORD: random
MYSQL_USER: test
Expand All @@ -138,6 +147,14 @@ jobs:
steps:
- setup_remote_docker:
docker_layer_caching: true
= run:
name: Login to Dockerhub
command: |
if [ "${DOCKER_USER}" == "" ] || [ "${DOCKER_PASS}" == "" ]; then
echo "Skipping Login to DockerHub, credentials unavailable"
else
echo "${DOCKER_PASS}" | docker login -u="${DOCKER_USER}" --password-stdin
fi
- checkout
- setup-rust
- setup-gcp-grpc
Expand Down Expand Up @@ -169,6 +186,9 @@ jobs:
e2e-tests:
docker:
- image: docker/compose:1.24.0
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
steps:
- setup_remote_docker
- restore_cache:
Expand All @@ -184,6 +204,9 @@ jobs:
deploy:
docker:
- image: docker:18.02.0-ce
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
steps:
- setup_remote_docker
- restore_cache:
Expand Down Expand Up @@ -219,6 +242,9 @@ jobs:
deploy-python-utils:
docker:
- image: docker:stable-git
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
steps:
- setup_remote_docker
- checkout
Expand Down