-
Notifications
You must be signed in to change notification settings - Fork 27
53 lines (43 loc) · 1.48 KB
/
explore_the_world.yml
File metadata and controls
53 lines (43 loc) · 1.48 KB
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
47
48
49
50
51
52
53
name: explore_the_world
on:
workflow_dispatch:
push:
branches:
- main
paths:
- 'explore_the_world/ui/*'
env:
IMAGE_NAME: deepset/demo-explore-the-world
jobs:
build-push:
name: Build and Push UI image
runs-on: ubuntu-latest
steps:
- name: Checkout
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
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_HUB_USER }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}
- name: Create driver
run: |
docker buildx create --use --name multi-builder --platform linux/amd64,linux/arm64
- name: Build and push amd64 image
working-directory: explore_the_world
run: |
docker buildx build -o type=docker -t $IMAGE_NAME:linux_amd64 --platform linux/amd64 -f Dockerfile .
docker push $IMAGE_NAME:linux_amd64
- name: Build and push arm64 image
working-directory: explore_the_world
run: |
docker buildx build -o type=docker -t $IMAGE_NAME:linux_arm64 --platform linux/arm64 -f Dockerfile .
docker push $IMAGE_NAME:linux_arm64
- name: Push manifest
run: |
docker manifest create $IMAGE_NAME:latest $IMAGE_NAME:linux_amd64 $IMAGE_NAME:linux_arm64
docker manifest push $IMAGE_NAME:latest