diff options
| author | MHSanaei <ho3ein.sanaei@gmail.com> | 2024-01-27 12:26:10 +0300 |
|---|---|---|
| committer | MHSanaei <ho3ein.sanaei@gmail.com> | 2024-01-27 18:37:17 +0300 |
| commit | f9c703ea44927ebd0c31ef9f7ed56aba00f90826 (patch) | |
| tree | 724ac136cc3ed08f5ce78fa049aadb6227c5e506 /Dockerfile | |
| parent | 9fba92d879767394535f70ba83f0a58d6b063a7d (diff) | |
remove multi protocol scriptv2.1.2
Diffstat (limited to 'Dockerfile')
| -rw-r--r-- | Dockerfile | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -1,11 +1,9 @@ # ======================================================== # Stage: Builder # ======================================================== -FROM --platform=$BUILDPLATFORM golang:1.21-alpine AS builder +FROM golang:1.21-alpine AS builder WORKDIR /app ARG TARGETARCH -ENV CGO_ENABLED=1 -ENV CGO_CFLAGS="-D_LARGEFILE64_SOURCE" RUN apk --no-cache --update add \ build-base \ @@ -15,6 +13,8 @@ RUN apk --no-cache --update add \ COPY . . +ENV CGO_ENABLED=1 +ENV CGO_CFLAGS="-D_LARGEFILE64_SOURCE" RUN go build -o build/x-ui main.go RUN ./DockerInit.sh "$TARGETARCH" @@ -30,9 +30,9 @@ RUN apk add --no-cache --update \ tzdata \ fail2ban -COPY --from=builder /app/build/ /app/ -COPY --from=builder /app/DockerEntrypoint.sh /app/ -COPY --from=builder /app/x-ui.sh /usr/bin/x-ui +COPY --from=builder /app/build/ /app/ +COPY --from=builder /app/DockerEntrypoint.sh /app/ +COPY --from=builder /app/x-ui.sh /usr/bin/x-ui # Configure fail2ban RUN rm -f /etc/fail2ban/jail.d/alpine-ssh.conf \ |
