-
Notifications
You must be signed in to change notification settings - Fork 2
46 lines (37 loc) · 1.32 KB
/
docker-image.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Build and Push Docker Image
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Log in to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Create and configure Docker Buildx builder
run: |
docker buildx create --use --name multiarch-builder --driver docker-container
docker buildx inspect --bootstrap
- name: Build and push multi-architecture image
run: |
docker buildx build --platform linux/amd64,linux/arm/v7,linux/arm64 -t iitgdocker/iperf-web:latest --push .
- name: push README to Dockerhub
uses: peter-evans/dockerhub-description@v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
short-description: A web interface for running iperf and other network utilities
repository: iitgdocker/iperf-web
env:
DOCKER_CLI_EXPERIMENTAL: enabled
DOCKER_BUILDKIT: 1