Skip to content

Commit 390ede3

Browse files
author
Qingping Hou
committed
fix docker login in release job
1 parent 1835288 commit 390ede3

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

Diff for: .github/workflows/cicd.yml

+7-1
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,13 @@ jobs:
3737
needs: test
3838
steps:
3939

40+
- name: Login to GitHub Container Registry
41+
uses: docker/login-action@v1
42+
with:
43+
registry: ghcr.io
44+
username: scribdbot
45+
password: ${{ secrets.SCRIBDBOT_GH_CONTAINER_REGISTRY_TOKEN }}
46+
4047
- name: Check out code into the Go module directory
4148
uses: actions/checkout@v2
4249

@@ -61,6 +68,5 @@ jobs:
6168
- name: Build and publish docker image
6269
run: |
6370
VERSION=${GITHUB_REF##*/}
64-
echo ${SCRIBDBOT_GH_CONTAINER_REGISTRY_TOKEN} | docker login ghcr.io -u scribdbot --password-stdin
6571
docker build --rm -t "ghcr.io/scribd/objinsync:${VERSION}" .
6672
docker push "ghcr.io/scribd/objinsync:${VERSION}"

Diff for: Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.16.3 as build
1+
FROM golang:1.16.5 as build
22
LABEL org.opencontainers.image.source https://github.com/scribd/objinsync
33
ADD . /app
44
WORKDIR /app

0 commit comments

Comments
 (0)