Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker nightly image #1684

Merged
merged 2 commits into from
Sep 21, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 79 additions & 0 deletions .github/workflows/publish-nightly-docker-images.yaml
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 * * *'
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will be run once a day at 1:00 am

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: Sparseml-Nightly latest using default cuda 11.1.1
uses: docker/build-push-action@v2
with:
context: ./docker
build-args: |
DEPS=all
BRANCH=main
push: true
tags: |
ghcr.io/neuralmagic/sparseml-nightly:latest
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sparseml-nightly:latest


- name: Today's Sparseml-Nightly using default cuda 11.1.1
uses: docker/build-push-action@v2
with:
context: ./docker
build-args: |
DEPS=all
BRANCH=main
push: true
tags: |
ghcr.io/neuralmagic/sparseml-nightly:${{ steps.extract_tag.outputs.tag }}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sparseml-nightly:YYYMMDD


- name: Today's Sparseml-Nightly Base using default cuda 11.1.1
uses: docker/build-push-action@v2
with:
context: ./docker
build-args: |
DEPS=base
BRANCH=main
push: true
tags: |
ghcr.io/neuralmagic/sparseml-nightly:base-${{ steps.extract_tag.outputs.tag }}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sparseml-nightly:base-YYYMMDD


- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}
Loading