* add Dockerfile * Create docker.yml * Update docker.yml * Update docker.yml * Update docker.yml * Update docker.yml * Update docker.yml * Update docker.yml * Update docker.yml * hardcode python version * install rustup * Revert "install rustup" This reverts commit 5f701ee084713bb633c7e840523574d96fa9191e. * Update docker.yml * Update docker.yml
45 lines
1.2 KiB
YAML
45 lines
1.2 KiB
YAML
on:
|
|
push:
|
|
pull_request:
|
|
release:
|
|
types: [published]
|
|
|
|
jobs:
|
|
docker:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository and submodules
|
|
uses: actions/checkout@v3
|
|
with:
|
|
submodules: recursive
|
|
- name: Set up Docker Buildx
|
|
id: buildx
|
|
uses: docker/setup-buildx-action@v2
|
|
- name: Login to GitHub Container Registry
|
|
uses: docker/login-action@v2
|
|
with:
|
|
registry: ghcr.io
|
|
username: ${{ github.repository_owner }}
|
|
password: ${{ secrets.GITHUB_TOKEN }}
|
|
- name: Set up QEMU
|
|
if: ${{ inputs.platforms != 'linux/amd64' }}
|
|
uses: docker/setup-qemu-action@v2
|
|
- name: Docker meta
|
|
id: meta
|
|
uses: docker/metadata-action@v4
|
|
with:
|
|
images: ${{ format('ghcr.io/{0}', github.repository) }}
|
|
tags: |
|
|
type=semver,pattern=v{{major}}
|
|
type=semver,pattern=v{{major}}.{{minor}}
|
|
type=ref,event=branch
|
|
type=ref,event=tag
|
|
- name: Build and push
|
|
uses: docker/build-push-action@v3
|
|
with:
|
|
context: .
|
|
push: ${{ github.event_name != 'pull_request' }}
|
|
tags: ${{ steps.meta.outputs.tags }}
|
|
labels: ${{ steps.meta.outputs.labels }}}
|
|
platforms: linux/amd64
|