Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/MHSanaei/3x-ui.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoritspooya <fallenangel201190@yahoo.com>2023-05-08 03:29:54 +0300
committerHo3ein <ho3ein.sanaei@gmail.com>2023-05-08 09:34:47 +0300
commit5c6406ab58517a34180ea6ae2d2e401bca112d9d (patch)
tree106cecdbb3c75c0923a45e7412cf33cb8d0c8686
parenta25137f215da573831ebb8b04165a9e787c94c61 (diff)
👷 Added Docker CI
-rw-r--r--Dockerfile7
1 files changed, 3 insertions, 4 deletions
diff --git a/Dockerfile b/Dockerfile
index 0d36d93b..876c4a57 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -13,12 +13,10 @@ RUN echo "GOOS=$TARGETOS GOARCH=$TARGETARCH" > /app/.env
COPY . .
# Build the X-ui binary
-RUN CGO_ENABLED=Û° GOOS=$TARGETOS GOARCH=$TARGETARCH go build -o xui-release-$TARGETARCH -v main.go
+RUN CGO_ENABLED=0 GOOS=$TARGETOS GOARCH=$TARGETARCH go build -o xui-release-$TARGETARCH -v main.go
# Start a new stage using the base image
FROM ubuntu:20.04
-ARG TARGETOS TARGETARCH
-RUN echo "TARGETOS=$TARGETOS TARGETARCH=$TARGETARCH"
# Set up the working directory
WORKDIR /app
@@ -45,7 +43,8 @@ RUN wget https://github.com/mhsanaei/Xray-core/releases/latest/download/Xray-lin
&& wget https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geoip.dat \
&& wget https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geosite.dat \
&& wget https://github.com/bootmortis/iran-hosted-domains/releases/latest/download/iran.dat \
- && mv xray xray-linux-$TARGETARCH
+ && arch=(dpkg --print-architecture) \
+ && mv xray xray-linux-$arch
WORKDIR /app
RUN chmod +x /app/x-ui/x-ui.sh