forked from yy4382/ms-ra-forwarder-for-ifreetime
-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (38 loc) · 1.13 KB
/
docker.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
name: Docker Image
on:
workflow_dispatch:
push:
branches: [ master ]
env:
DOCKER_REPOSITORY: yunfinibol/ms-ra-forwarder-for-ifreetime
jobs:
build:
runs-on: ubuntu-latest
if: github.repository == 'yy4382/ms-ra-forwarder-for-ifreetime'
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Docker setup QEMU
uses: docker/[email protected]
- name: Docker setup Buildx
uses: docker/[email protected]
- name: Docker login
uses: docker/[email protected]
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Create docker image tag
run: echo DATE_TAG=$(date +%y%m%d%H%M%S) >> $GITHUB_ENV
- name: Build and push docker image
uses: docker/[email protected]
with:
push: true
platforms: |
linux/amd64
linux/arm/v7
linux/arm64/v8
linux/ppc64le
linux/s390x
tags: |
${{ env.DOCKER_REPOSITORY }}:${{ env.DATE_TAG }}
${{ env.DOCKER_REPOSITORY }}:latest