-
Notifications
You must be signed in to change notification settings - Fork 70
76 lines (65 loc) · 1.93 KB
/
build.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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
name: Docker Hub Release
on:
push:
branches: [ master ]
jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Docker
uses: docker/setup-buildx-action@v2
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
- name: Base Generate Tags
uses: docker/metadata-action@v4
id: metadata
with:
images: |
${{ github.repository_owner }}/pallas-bot
tags: |
type=raw,value=latest
- name: Base Build and Publish
uses: docker/build-push-action@v4
with:
context: .
file: Dockerfile
push: true
tags: ${{ steps.metadata.outputs.tags }}
labels: ${{ steps.metadata.outputs.labels }}
- name: AI on GPU Generate Tags
uses: docker/metadata-action@v4
id: gpuaimetadata
with:
images: |
misteo/pallas-bot
tags: |
type=raw,value=gpuai-latest
- name: AI on GPU Build and Publish
uses: docker/build-push-action@v4
with:
context: .
file: GPU.Dockerfile
push: true
tags: ${{ steps.gpuaimetadata.outputs.tags }}
labels: ${{ steps.gpuaimetadata.outputs.labels }}
- name: AI on CPU Generate Tags
uses: docker/metadata-action@v4
id: cpuaimetadata
with:
images: |
misteo/pallas-bot
tags: |
type=raw,value=cpuai-latest
- name: AI on CPU Build and Publish
uses: docker/build-push-action@v4
with:
context: .
file: CPU.Dockerfile
push: true
tags: ${{ steps.cpuaimetadata.outputs.tags }}
labels: ${{ steps.cpuaimetadata.outputs.labels }}