mirror of
https://github.com/amnezia-vpn/amneziawg-go.git
synced 2025-04-08 01:56:56 +02:00
commit
7155d20913
1 changed files with 6 additions and 12 deletions
18
Dockerfile
18
Dockerfile
|
@ -5,16 +5,10 @@ RUN go mod download && \
|
|||
go mod verify && \
|
||||
go build -ldflags '-linkmode external -extldflags "-fno-PIC -static"' -v -o /usr/bin
|
||||
|
||||
FROM alpine:3.15 as awg-tools
|
||||
ARG AWGTOOLS_RELEASE="1.0.20231215"
|
||||
RUN apk --no-cache add linux-headers build-base bash && \
|
||||
wget https://github.com/amnezia-vpn/amneziawg-tools/archive/refs/tags/v${AWGTOOLS_RELEASE}.zip && \
|
||||
unzip v${AWGTOOLS_RELEASE}.zip && \
|
||||
cd amneziawg-tools-${AWGTOOLS_RELEASE}/src && \
|
||||
make -e LDFLAGS=-static && \
|
||||
make install
|
||||
|
||||
FROM alpine:3.15
|
||||
RUN apk --no-cache add iproute2 bash
|
||||
FROM alpine:3.19
|
||||
ARG AWGTOOLS_RELEASE="1.0.20240202"
|
||||
RUN apk --no-cache add iproute2 bash && \
|
||||
wget https://github.com/amnezia-vpn/amneziawg-tools/releases/download/v${AWGTOOLS_RELEASE}/alpine-3.19-amneziawg-tools.zip && \
|
||||
unzip alpine-3.19-amneziawg-tools.zip -d /usr/bin/ && \
|
||||
chmod +x /usr/bin/wg /usr/bin/wg-quick
|
||||
COPY --from=awg /usr/bin/amneziawg-go /usr/bin/amneziawg-go
|
||||
COPY --from=awg-tools /usr/bin/awg /usr/bin/awg-quick /usr/bin/
|
||||
|
|
Loading…
Add table
Reference in a new issue