From 79835f64147630b3416d55c0b9be69156a4b66cd Mon Sep 17 00:00:00 2001 From: Mike Evans Date: Thu, 22 Jun 2023 17:42:59 +0100 Subject: [PATCH] fix: enable full version alpine build only --- .../build-singbox-docker-mainline.yml | 4 ++-- .github/workflows/build-singbox-docker.yml | 8 ++++---- README.md | 18 ++++-------------- dockerfiles/Dockerfile.standard | 2 +- 4 files changed, 11 insertions(+), 21 deletions(-) diff --git a/.github/workflows/build-singbox-docker-mainline.yml b/.github/workflows/build-singbox-docker-mainline.yml index 8cefee5..0620dcc 100644 --- a/.github/workflows/build-singbox-docker-mainline.yml +++ b/.github/workflows/build-singbox-docker-mainline.yml @@ -12,8 +12,8 @@ jobs: strategy: fail-fast: true matrix: - buildType: [standard, minimized, full] - distro: [alpine, distroless] + buildType: [full] + distro: [alpine] runs-on: ubuntu-latest steps: - name: Checkout Source Code of 'SagerNet/sing-box' diff --git a/.github/workflows/build-singbox-docker.yml b/.github/workflows/build-singbox-docker.yml index e408c30..4562305 100644 --- a/.github/workflows/build-singbox-docker.yml +++ b/.github/workflows/build-singbox-docker.yml @@ -12,8 +12,8 @@ jobs: strategy: fail-fast: true matrix: - buildType: [standard, minimized, full] - distro: [alpine, distroless] + buildType: [full] + distro: [alpine] runs-on: ubuntu-latest steps: - name: Checkout Source Code of 'SagerNet/sing-box' @@ -70,10 +70,10 @@ jobs: - name: Get tag to build id: tag run: | - if [[ "${{ matrix.distro }}" == "alpine" && "${{ matrix.buildType }}" == "standard" ]]; then + if [[ "${{ matrix.distro }}" == "alpine" && "${{ matrix.buildType }}" == "full" ]]; then echo "latest=etnperlong/sing-box:latest" >> $GITHUB_OUTPUT fi - if [[ "${{ matrix.distro }}" == "distroless" && "${{ matrix.buildType }}" == "standard" ]]; then + if [[ "${{ matrix.distro }}" == "distroless" && "${{ matrix.buildType }}" == "full" ]]; then echo "latest=etnperlong/sing-box:distroless" >> $GITHUB_OUTPUT fi if [[ -z "${{ github.event.inputs.tag }}" ]]; then diff --git a/README.md b/README.md index 88ee7a3..4b8a728 100644 --- a/README.md +++ b/README.md @@ -4,9 +4,9 @@ [sing-box](https://sing-box.sagernet.org/) is a universal proxy platform for building your own proxy. -Docker images are built for quick deployment in various computing cloud providers. +Docker images are designed for rapid deployment to various computing cloud providers. -For more information on docker and containerization technologies, refer to [official document](https://docs.docker.com/). +For more information on Docker and containerization technologies, read the [official document](https://docs.docker.com/). ## Documentation @@ -22,15 +22,9 @@ For more information on docker and containerization technologies, refer to [offi ## Enabled features -- `standard` -> `with_gvisor,with_quic,with_wireguard,with_utls,with_reality_server,with_clash_api,with_acme` - -- `full` +**Full version!** > `with_gvisor,with_quic,with_grpc,with_dhcp,with_wireguard,with_shadowsocksr,with_ech,with_utls,with_reality_server,with_clash_api,with_v2ray_api,with_acme` -- `mini` -> `with_quic,with_utls,with_reality_server` - ## Supported tags - `latest` *([latest release](https://github.com/SagerNet/sing-box/releases))* @@ -38,8 +32,4 @@ For more information on docker and containerization technologies, refer to [offi - `dev` *([dev branch](https://github.com/SagerNet/sing-box/tree/dev))* - `dev-next` *([dev-next branch](https://github.com/SagerNet/sing-box/tree/dev))* -## Additional distro - -Add `-distroless` to the end of the tag to use the build of distroless images. - -For example, `etnperlong/sing-box:dev-next-full-distroless` is the distroless build of full feature enabled image. +For example, `etnperlong/sing-box:dev-next` means a fully functional docker image. diff --git a/dockerfiles/Dockerfile.standard b/dockerfiles/Dockerfile.standard index bd49446..0054c9c 100644 --- a/dockerfiles/Dockerfile.standard +++ b/dockerfiles/Dockerfile.standard @@ -9,7 +9,7 @@ RUN set -ex \ && apk add git build-base \ && export COMMIT=$(git rev-parse --short HEAD) \ && export VERSION=$(go run ./cmd/internal/read_tag) \ - && go build -v -trimpath -tags with_gvisor,with_quic,with_wireguard,with_utls,with_reality_server,with_clash_api,with_acme \ + && go build -v -trimpath -tags with_gvisor,with_quic,with_dhcp,with_wireguard,with_utls,with_reality_server,with_clash_api,with_acme \ -o /go/bin/sing-box \ -ldflags "-X \"github.com/sagernet/sing-box/constant.Version=$VERSION\" -s -w -buildid=" \ ./cmd/sing-box