forked from m3ue/m3u-proxy
-
Notifications
You must be signed in to change notification settings - Fork 0
101 lines (86 loc) · 2.84 KB
/
publish_dev.yml
File metadata and controls
101 lines (86 loc) · 2.84 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
name: Dev
on:
push:
branches: [dev]
jobs:
ci:
name: Run CI
uses: ./.github/workflows/ci.yml
secrets: inherit
push-amd64:
needs: [ci]
name: Publish dev m3u-proxy Docker image (amd64)
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push amd64
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64
push: true
tags: ${{ secrets.DOCKERHUB_USERNAME }}/m3u-proxy:dev-amd64
build-args: |
GIT_BRANCH=${{ github.ref_name }}
GIT_COMMIT=${{ github.sha }}
GIT_TAG=${{ github.ref_type == 'tag' && github.ref_name || '' }}
provenance: false
sbom: false
push-arm64:
needs: [ci]
name: Publish dev m3u-proxy Docker image (arm64)
runs-on: ubuntu-22.04-arm
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push arm64
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/arm64
push: true
tags: ${{ secrets.DOCKERHUB_USERNAME }}/m3u-proxy:dev-arm64
build-args: |
GIT_BRANCH=${{ github.ref_name }}
GIT_COMMIT=${{ github.sha }}
GIT_TAG=${{ github.ref_type == 'tag' && github.ref_name || '' }}
provenance: false
sbom: false
push-manifest:
name: Push Docker Manifest for dev
runs-on: ubuntu-latest
needs: [push-amd64, push-arm64]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Create manifest list
run: |
docker manifest create ${{ secrets.DOCKERHUB_USERNAME }}/m3u-proxy:dev \
${{ secrets.DOCKERHUB_USERNAME }}/m3u-proxy:dev-amd64 \
${{ secrets.DOCKERHUB_USERNAME }}/m3u-proxy:dev-arm64
- name: Push manifest list
run: docker manifest push ${{ secrets.DOCKERHUB_USERNAME }}/m3u-proxy:dev