Skip to content

Commit

Permalink
add workflow to build Notebook Docker Image
Browse files Browse the repository at this point in the history
  • Loading branch information
jtroe committed Oct 4, 2023
1 parent 5288b29 commit dbf893a
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/DockerBuild.NotebookImage.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: DockerBuild.NotebookImage

on:
# allow it to be run on-demand
workflow_dispatch:

jobs:
build-and-push:
name: Build Docker image and push to ghcr.io
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2

- name: Login to Github Packages
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: |
ghcr.io/esri/arcgis-python-api-notebook
tags: |
type=raw,value=2.3.0,enable={{is_default_branch}}
type=raw,value=latest,enable={{is_default_branch}}
type=schedule,pattern={{date 'YY.MM'}},enable={{is_default_branch}}
type=sha,format=long
- id: docker_build
name: Build image and push to GitHub Container Registry
uses: docker/build-push-action@v4
with:
# relative path to the place where source code with Dockerfile is located
context: ./docker
file: ./docker/NotebookImage.Dockerfile
tags: ${{ steps.meta.outputs.tags }}
provenance: false
platforms: linux/amd64
push: true
File renamed without changes.

0 comments on commit dbf893a

Please sign in to comment.