File tree 1 file changed +58
-0
lines changed
1 file changed +58
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ name : docker-publish
3
+ on :
4
+ push :
5
+ tags :
6
+ - ' *'
7
+
8
+ permissions :
9
+ packages : write
10
+
11
+ jobs :
12
+ docker-publish :
13
+ runs-on : ubuntu-latest
14
+
15
+ steps :
16
+ - name : Checkout
17
+ uses : actions/checkout@v2
18
+
19
+ # https://github.com/docker/setup-qemu-action
20
+ - name : Set up QEMU
21
+ uses : docker/setup-qemu-action@v2
22
+
23
+ # https://github.com/docker/setup-buildx-action
24
+ - name : Set up Docker Buildx
25
+ uses : docker/setup-buildx-action@v2
26
+
27
+ - name : Login to GHCR
28
+ uses : docker/login-action@v2
29
+ with :
30
+ registry : ghcr.io
31
+ username : ${{ github.repository_owner }}
32
+ password : ${{ secrets.GITHUB_TOKEN }}
33
+
34
+ # https://github.com/docker/metadata-action
35
+ - name : Docker meta
36
+ id : meta
37
+ uses : docker/metadata-action@v4
38
+ with :
39
+ # List of Docker images to use as base name for tags
40
+ images : |
41
+ ghcr.io/mafrosis/tinytuya2mqtt
42
+ # Docker tags based on the following events/attributes
43
+ tags : |
44
+ type=schedule
45
+ type=ref,event=branch
46
+ type=ref,event=pr
47
+ type=pep440,pattern={{version}},value=${{ steps.version.outputs.version }}
48
+ type=sha
49
+
50
+ # https://github.com/docker/build-push-action
51
+ - name : Build and push
52
+ uses : docker/build-push-action@v3
53
+ with :
54
+ context : .
55
+ push : true
56
+ platforms : linux/arm64,linux/amd64,linux/arm/v7
57
+ tags : ${{ steps.meta.outputs.tags }}
58
+ labels : ${{ steps.meta.outputs.labels }}
You can’t perform that action at this time.
0 commit comments