Skip to content

Commit 72130c1

Browse files
committed
feat(typescript-node): update workflow config
1 parent be5cf47 commit 72130c1

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

.github/workflows/typescript-node-nightly.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77
- 'source/typescript-node/Dockerfile'
88

99
jobs:
10-
build:
10+
build-and-push:
1111
runs-on: ubuntu-latest
1212
steps:
1313
- uses: actions/checkout@v4
@@ -17,19 +17,19 @@ jobs:
1717

1818
- name: Login to Docker Hub
1919
run: |
20-
docker login -u ${{ secrets.DOCKERHUB_USERNAME }} -p ${{ secrets.DOCKERHUB_TOKEN }}
20+
echo ${{ secrets.DOCKERHUB_TOKEN }} | docker login -u ${{ secrets.DOCKERHUB_USERNAME }} --password-stdin
2121
22-
- name: Generate nightly ID with commit
22+
- name: Generate build tag
2323
run: |
2424
TIMESTAMP=$(date +'%Y%m%d')
2525
SHA=$(git rev-parse --short HEAD)
26-
echo "NIGHTLY_ID=nightly-${TIMESTAMP}-${SHA}" >> $GITHUB_ENV
26+
echo "BUILD_TAG=nightly-${TIMESTAMP}-${SHA}" >> $GITHUB_ENV
2727
2828
- name: Build & Push Docker image
2929
uses: docker/build-push-action@v6
3030
with:
3131
context: source/typescript-node
3232
push: true
33-
tags: ${{ secrets.DOCKERHUB_USERNAME }}/typescript-node:nightly-${{ env.NIGHTLY_ID }}
33+
tags: ${{ secrets.DOCKERHUB_USERNAME }}/typescript-node:${{ env.BUILD_TAG }}
3434
cache-from: type=gha
3535
cache-to: type=gha,mode=max

0 commit comments

Comments
 (0)