Merge pull request #12 from lasp/dependabot/pip/certifi-2023.7.22 #18
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
name: Publish | |
on: | |
push: | |
branches: | |
- develop | |
tags: | |
- v* | |
env: | |
REGISTRY: ghcr.io | |
BSK_VERSION: "2.1.7" | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
permissions: | |
checks: write | |
contents: read | |
packages: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Checkout Basilisk | |
uses: actions/checkout@v3 | |
with: | |
repository: AVSLab/basilisk | |
ref: ${{ env.BSK_VERSION }} | |
lfs: true | |
path: basilisk | |
- name: Login to the Container Registry | |
uses: docker/login-action@v2 | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ github.token }} | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
with: | |
platforms: linux/amd64,linux/arm64 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
# Build, scan, and push basilisk-jupyterlabs Docker artifacts. | |
- name: Extract metadata (tags, labels) for basilisk-jupyterlabs Docker image | |
id: metadata | |
uses: docker/metadata-action@v4 | |
with: | |
images: ${{ env.REGISTRY }}/lasp/basilisk-jupyterlabs | |
tags: type=raw, value=${{ env.BSK_VERSION }} | |
- name: Build basilisk-jupyterlabs Docker image | |
uses: docker/build-push-action@v3 | |
with: | |
context: . | |
file: basilisk-jupyterlabs.Containerfile | |
load: true | |
tags: ${{ env.REGISTRY }}/lasp/basilisk-jupyterlabs:${{ github.sha }} | |
- name: Scan basilisk-jupyterlabs Docker image | |
uses: aquasecurity/trivy-action@master | |
with: | |
image-ref: ${{ env.REGISTRY }}/lasp/basilisk-jupyterlabs:${{ github.sha }} | |
format: 'table' | |
exit-code: '0' | |
ignore-unfixed: true | |
severity: 'CRITICAL' | |
timeout: 10m0s | |
- name: Push basilisk-jupyterlabs Docker image | |
uses: docker/build-push-action@v3 | |
with: | |
context: . | |
file: basilisk-jupyterlabs.Containerfile | |
platforms: linux/amd64,linux/arm64 | |
push: true | |
tags: ${{ steps.metadata.outputs.tags }} | |
labels: ${{ steps.metadata.outputs.labels }} |