From de79418183d0a6ecd054bfc13af07af55b2a95bf Mon Sep 17 00:00:00 2001 From: real-alchemist <163184960+real-alchemist@users.noreply.github.com> Date: Wed, 13 Mar 2024 10:05:00 +0330 Subject: [PATCH] add dockerfile --- Dockerfile | 17 +++++++++++++++++ hiddify.json | 41 +++++++++++++++++++++++++++++++++++++++++ hiddify.sh | 2 ++ 3 files changed, 60 insertions(+) create mode 100644 Dockerfile create mode 100644 hiddify.json create mode 100644 hiddify.sh diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..0f73b9a --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM alpine:latest +ENV CONFIG='https://raw.githubusercontent.com/ircfspace/warpsub/main/export/warp#WARP%20(IRCF)' +ENV VERSION=v0.17.8 +WORKDIR /opt +RUN apk add wget tar gzip libc6-compat +RUN export ARCH=$(apk --print-arch) && if [ "$ARCH" = "i386" ]; then ARCH="386"; elif [ "$ARCH" = "x86_64" ]; then ARCH="amd64"; fi && wget https://github.com/hiddify/hiddify-next-core/releases/download/${VERSION}/hiddify-cli-linux-$ARCH.tar.gz -O hiddify-cli.tar.gz +RUN tar -xzf hiddify-cli.tar.gz && rm hiddify-cli.tar.gz +COPY hiddify.sh . +COPY hiddify.json . +RUN chmod +x hiddify.sh + +EXPOSE 2334 +EXPOSE 6756 +EXPOSE 6450 + + +ENTRYPOINT [ "/opt/hiddify.sh" ] \ No newline at end of file diff --git a/hiddify.json b/hiddify.json new file mode 100644 index 0000000..48a7172 --- /dev/null +++ b/hiddify.json @@ -0,0 +1,41 @@ +{ + "service-mode": "proxy", + "log-level": "info", + "resolve-destination": true, + "ipv6-mode": "prefer_ipv4", + "remote-dns-address": "tcp://1.1.1.1", + "remote-dns-domain-strategy": "", + "direct-dns-address": "1.1.1.1", + "direct-dns-domain-strategy": "", + "mixed-port": 2334, + "local-dns-port": 6450, + "tun-implementation": "mixed", + "mtu": 9000, + "strict-route": false, + "connection-test-url": "https://www.gstatic.com/generate_204", + "url-test-interval": 600, + "enable-clash-api": true, + "clash-api-port": 6756, + "bypass-lan": false, + "allow-connection-from-lan": true, + "enable-fake-dns": false, + "enable-dns-routing": true, + "independent-dns-cache": true, + "enable-tls-fragment": false, + "tls-fragment-size": "20-70", + "tls-fragment-sleep": "10-30", + "enable-tls-mixed-sni-case": false, + "enable-tls-padding": false, + "tls-padding-size": "15-30", + "enable-mux": false, + "mux-padding": false, + "mux-max-streams": 4, + "mux-protocol": "h2mux", + "enable-warp": false, + "warp-detour-mode": "outbound", + "warp-license-key": "", + "warp-clean-ip": "auto", + "warp-port": 0, + "warp-noise": "5-10", + "warp-noise-delay": "20-200" +} \ No newline at end of file diff --git a/hiddify.sh b/hiddify.sh new file mode 100644 index 0000000..4f70655 --- /dev/null +++ b/hiddify.sh @@ -0,0 +1,2 @@ +#!/bin/sh +/opt/HiddifyCli run --config $CONFIG -h /opt/hiddify.json