Document how to use this container for exposing host ports #35
Workflow file for this run
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: Build multi-arch Docker Image | |
on: | |
release: | |
types: [published] | |
push: | |
branches: [main] | |
pull_request: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Login to Docker Hub | |
# Only if we need to push an image | |
if: ${{ github.event_name == 'release' && github.event.action == 'published' }} | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
# Setup for buildx | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
with: | |
image: tonistiigi/binfmt:qemu-v6.0.0-12 | |
- name: Set up Docker Buildx | |
id: buildx | |
uses: docker/setup-buildx-action@v3 | |
with: | |
version: v0.6.1 | |
# Debugging information | |
- name: Docker info | |
run: docker info | |
- name: Buildx inspect | |
run: docker buildx inspect | |
# Build and (optionally) push the image | |
- name: Build image | |
uses: docker/build-push-action@v6 | |
with: | |
context: . | |
file: ./Dockerfile | |
platforms: linux/amd64,linux/arm/v7,linux/arm64,linux/ppc64le,linux/s390x | |
# Only push if we are publishing a release | |
push: ${{ github.event_name == 'release' && github.event.action == 'published' }} | |
# Use a 'temp' tag, that won't be pushed, for non-release builds | |
tags: testcontainers/sshd:${{ github.event.release.tag_name || 'temp' }} |