49
49
- uses : softprops/action-gh-release@v1
50
50
if : startsWith(github.ref, 'refs/tags/')
51
51
with :
52
- files : ${{ matrix.filename }}
52
+ files : ${{ matrix.filename }}
53
+ - run : mv ${{ matrix.filename }} git-backup
54
+ - uses : actions/upload-artifact@v2
55
+ with :
56
+ name : binary-${{ matrix.filename }}
57
+ path : git-backup
58
+ build_docker :
59
+ needs :
60
+ - build
61
+ name : Build Docker
62
+ runs-on : ubuntu-20.04
63
+ steps :
64
+ - uses : actions/checkout@v2
65
+ - uses : actions/download-artifact@v2
66
+ with :
67
+ name : binary-git-backup-linux-x64
68
+ path : linux/amd64/git-backup
69
+ - uses : actions/download-artifact@v2
70
+ with :
71
+ name : binary-git-backup-linux-armv7
72
+ path : linux/arm/v7/git-backup
73
+ - run : find linux
74
+ - uses : docker/setup-qemu-action@v1
75
+ - uses : docker/setup-buildx-action@v1
76
+ - uses : docker/login-action@v1
77
+ with :
78
+ registry : ghcr.io
79
+ username : ${{ github.repository_owner }}
80
+ password : ${{ secrets.GITHUB_TOKEN }}
81
+ - name : Docker meta
82
+ id : meta
83
+ uses : docker/metadata-action@v3
84
+ with :
85
+ images : ghcr.io/chappio/git-backup
86
+ tags : |
87
+ type=ref,event=pr
88
+ type=semver,pattern={{version}}
89
+ type=semver,pattern={{major}}.{{minor}}
90
+ type=semver,pattern={{major}}
91
+ type=edge,branch=main
92
+ - uses : docker/build-push-action@v2
93
+ with :
94
+ context : .
95
+ platforms : linux/amd64,linux/arm/v7
96
+ push : true
97
+ tags : ${{ steps.meta.outputs.tags }}
98
+ labels : ${{ steps.meta.outputs.labels }}
0 commit comments