Skip to content

Try to get the mutants container user going #25

Try to get the mutants container user going

Try to get the mutants container user going #25

Workflow file for this run

# Create a container image with the Rust toolchain and the cargo-mutants binary.
#
# TODO: Maybe cross build to Arm using `cross` instead of running everything under emulation.
name: Build and Push Container Image
env:
REGISTRY: ghcr.io
on:
push:
branches:
- main
- container
jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
attestations: write
id-token: write
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract Docker metadata
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ github.repository }}
- name: Build and push container image
id: push
# --platform linux/amd64,linux/arm64
run: |
docker build --push -t ghcr.io/sourcefrog/cargo-mutants:container .
# - name: Generate artifact attestation
# uses: actions/attest-build-provenance@v2
# with:
# subject-name: ${{ env.REGISTRY }}/${{ github.repository }}
# subject-digest: ${{ steps.push.outputs.digest }}
# push-to-registry: true