Skip to content

Commit bac45c9

Browse files
authored
ci: add nightly release
1 parent 30553a1 commit bac45c9

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

.github/workflows/release.yaml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Nightly Release
2+
on:
3+
schedule:
4+
- cron: '0 0 * * *'
5+
workflow_dispatch: {}
6+
jobs:
7+
build-release:
8+
name: Build and release Docker image
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Checkout repository
12+
uses: actions/checkout@v2
13+
- name: Login into GitHub Container Registry
14+
run: echo ${{ secrets.CR_PAT }} | docker login ghcr.io -u $GITHUB_ACTOR --password-stdin
15+
- name: Build Docker image
16+
run: |
17+
docker build \
18+
-t "ghcr.io/${GITHUB_REPOSITORY}:${GITHUB_SHA:0:7}" \
19+
-t "ghcr.io/${GITHUB_REPOSITORY}:nightly" .
20+
- name: Release Docker image
21+
run: docker push "ghcr.io/${GITHUB_REPOSITORY}"

0 commit comments

Comments
 (0)