Skip to content

Commit 1791be0

Browse files
maderwinclaude
andcommitted
fix(ci): login to cr.yandex after build to avoid Docker Hub auth conflict
docker login for cr.yandex pollutes ~/.docker/config.json, causing Docker Hub pulls during build to send wrong credentials. Moving login after build ensures base image pulls use anonymous Docker Hub auth. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 02289ae commit 1791be0

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

.github/workflows/ci.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,15 @@ jobs:
4343
steps:
4444
- uses: actions/checkout@v4
4545

46-
- name: Login to YC Container Registry
47-
run: echo '${{ secrets.YC_SA_KEY_JSON }}' | docker login cr.yandex -u json_key --password-stdin
48-
49-
- name: Build
50-
run: docker build -t cr.yandex/crpml6ifd12s8cbmbg3m/atlas:latest -t cr.yandex/crpml6ifd12s8cbmbg3m/atlas:${{ github.sha }} .
46+
- name: Build image
47+
run: |
48+
docker build \
49+
-t cr.yandex/crpml6ifd12s8cbmbg3m/atlas:latest \
50+
-t cr.yandex/crpml6ifd12s8cbmbg3m/atlas:${{ github.sha }} \
51+
.
5152
52-
- name: Push
53+
- name: Push to YC Container Registry
5354
run: |
55+
echo '${{ secrets.YC_SA_KEY_JSON }}' | docker login cr.yandex -u json_key --password-stdin
5456
docker push cr.yandex/crpml6ifd12s8cbmbg3m/atlas:latest
5557
docker push cr.yandex/crpml6ifd12s8cbmbg3m/atlas:${{ github.sha }}

0 commit comments

Comments
 (0)