Skip to content

docker

docker #289

Workflow file for this run

# The point of this job is to re-build docker base images once a day so
# that upstream package updates are reflected and dependency security
# vulns don't become an issue.
name: docker
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch: {}
jobs:
docker:
if: ${{ github.ref == 'refs/heads/main' }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
with:
install: true
- name: Login to DockerHub
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push release
uses: docker/build-push-action@v3
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: ghcr.io/opensanctions/opensanctions:latest
cache-to: type=registry,ref=ghcr.io/opensanctions/opensanctions:buildcache,mode=max