49 lines
1.2 KiB
YAML
49 lines
1.2 KiB
YAML
name: "Latest tag from master branch"
|
|
env:
|
|
DOCKERHUB_REPOSITORY: serjs/go-socks5-proxy
|
|
|
|
on:
|
|
pull_request:
|
|
branches: master
|
|
push:
|
|
branches: master
|
|
|
|
jobs:
|
|
hadolint:
|
|
name: hadolint
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@master
|
|
- name: hadolint
|
|
uses: hadolint/hadolint-action@v1.5.0
|
|
with:
|
|
ignore: DL3018
|
|
buildx:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
-
|
|
name: Checkout
|
|
uses: actions/checkout@v1
|
|
-
|
|
name: Set up Docker Buildx
|
|
id: buildx
|
|
uses: crazy-max/ghaction-docker-buildx@v1.1.0
|
|
-
|
|
name: Print builder available platforms
|
|
run: echo ${{ steps.buildx.outputs.platforms }}
|
|
-
|
|
name: Dockerhub login
|
|
uses: docker/login-action@v2
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
|
-
|
|
name: Run Buildx for amd64, armv7, arm64 architectures
|
|
run: |
|
|
docker buildx build \
|
|
--platform linux/amd64,linux/arm/v7,linux/arm64 \
|
|
--output "type=image,push=false" \
|
|
--push \
|
|
--tag "$DOCKERHUB_REPOSITORY:latest" \
|
|
.
|