mirror of
https://github.com/SagerNet/sing-box.git
synced 2024-11-26 02:21:28 +00:00
Update container action
This commit is contained in:
parent
14452f3049
commit
f3d1b59173
11
.github/workflows/docker.yml
vendored
11
.github/workflows/docker.yml
vendored
|
@ -15,6 +15,8 @@ jobs:
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
- name: Setup Docker Buildx
|
- name: Setup Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v1
|
uses: docker/setup-buildx-action@v1
|
||||||
|
- name: Setup QEMU for Docker Buildx
|
||||||
|
uses: docker/setup-qemu-action@v2
|
||||||
- name: Login to GitHub Container Registry
|
- name: Login to GitHub Container Registry
|
||||||
uses: docker/login-action@v1
|
uses: docker/login-action@v1
|
||||||
with:
|
with:
|
||||||
|
@ -29,15 +31,18 @@ jobs:
|
||||||
- name: Get tag to build
|
- name: Get tag to build
|
||||||
id: tag
|
id: tag
|
||||||
run: |
|
run: |
|
||||||
|
echo "latest=ghcr.io/sagernet/sing-box:latest" >> $GITHUB_OUTPUT
|
||||||
if [[ -z "${{ github.event.inputs.tag }}" ]]; then
|
if [[ -z "${{ github.event.inputs.tag }}" ]]; then
|
||||||
echo ::set-output name=tag::ghcr.io/sagernet/sing-box:${{ github.ref_name }}
|
echo "versioned=ghcr.io/sagernet/sing-box:${{ github.ref_name }}" >> $GITHUB_OUTPUT
|
||||||
else
|
else
|
||||||
echo ::set-output name=tag::ghcr.io/sagernet/sing-box:${{ github.event.inputs.tag }}
|
echo "versioned=ghcr.io/sagernet/sing-box:${{ github.event.inputs.tag }}" >> $GITHUB_OUTPUT
|
||||||
fi
|
fi
|
||||||
- name: Build and release Docker images
|
- name: Build and release Docker images
|
||||||
uses: docker/build-push-action@v2
|
uses: docker/build-push-action@v2
|
||||||
with:
|
with:
|
||||||
platforms: linux/386,linux/amd64,linux/arm64,linux/s390x
|
platforms: linux/386,linux/amd64,linux/arm64,linux/s390x
|
||||||
target: dist
|
target: dist
|
||||||
tags: ${{ steps.tag.outputs.tag }}
|
tags: |
|
||||||
|
${{ steps.tag.outputs.latest }}
|
||||||
|
${{ steps.tag.outputs.versioned }}
|
||||||
push: true
|
push: true
|
||||||
|
|
Loading…
Reference in a new issue