Skip to content

Commit

Permalink
Merge pull request #2118 from yarikoptic/enh-no-dockerlogin
Browse files Browse the repository at this point in the history
Login to docker hub only if credentials were provided
  • Loading branch information
yarikoptic authored Dec 19, 2024
2 parents cdeb572 + 1da1253 commit 9bf49de
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/cli-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@ jobs:

- name: Build Docker image
run: |
docker login -u "$DOCKER_LOGIN" --password-stdin <<<"$DOCKER_TOKEN"
if [ -n "$DOCKER_LOGIN$DOCKER_TOKEN" ]; then
docker login -u "$DOCKER_LOGIN" --password-stdin <<<"$DOCKER_TOKEN"
else
echo "Not logging in to docker since no credentials were provided, might hit limits below"
fi
docker build \
-t dandiarchive/dandiarchive-api \
-f dev/django-public.Dockerfile \
Expand Down

0 comments on commit 9bf49de

Please sign in to comment.