-
Notifications
You must be signed in to change notification settings - Fork 168
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add workflow for building and pushing nightly deepsparse docker images (
- Loading branch information
1 parent
8f6d5a2
commit dd4850c
Showing
1 changed file
with
79 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
name: Publish Nightly Docker Images | ||
|
||
on: | ||
push: | ||
branches: | ||
- 'main' | ||
schedule: | ||
- cron: '0 1 * * *' | ||
workflow_dispatch: | ||
jobs: | ||
push-nightly-docker-image: | ||
name: Push Version Tagged Nightly Docker Images | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
packages: write | ||
|
||
steps: | ||
- name: Set up Docker Buildx | ||
id: buildx | ||
uses: docker/setup-buildx-action@v2 | ||
with: | ||
buildkitd-flags: --debug | ||
|
||
- name: Login to Github Packages | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 1 | ||
|
||
- name: Get version tag | ||
id: extract_tag | ||
run: echo "tag=$(date +%Y%m%d)" >> $GITHUB_OUTPUT | ||
|
||
- name: Current Version Name | ||
run: | | ||
echo ${{ steps.extract_tag.outputs.tag }} | ||
- name: DeepSparse-Nightly latest | ||
uses: docker/build-push-action@v2 | ||
with: | ||
context: ./docker | ||
build-args: | | ||
DEPS=all | ||
BRANCH=main | ||
push: true | ||
tags: | | ||
ghcr.io/neuralmagic/deepsparse-nightly:latest | ||
- name: Today's DeepSparse-Nightly | ||
uses: docker/build-push-action@v2 | ||
with: | ||
context: ./docker | ||
build-args: | | ||
DEPS=all | ||
BRANCH=main | ||
push: true | ||
tags: | | ||
ghcr.io/neuralmagic/deepsparse-nightly:${{ steps.extract_tag.outputs.tag }} | ||
- name: Today's DeepSparse-Nightly Base | ||
uses: docker/build-push-action@v2 | ||
with: | ||
context: ./docker | ||
build-args: | | ||
DEPS=base | ||
BRANCH=main | ||
push: true | ||
tags: | | ||
ghcr.io/neuralmagic/deepsparse-nightly:base-${{ steps.extract_tag.outputs.tag }} | ||
- name: Image digest | ||
run: echo ${{ steps.docker_build.outputs.digest }} |