mirror of https://github.com/v2ray/v2ray-core
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
684 B
17 lines
684 B
############################ |
|
# STEP 1 build executable binary |
|
############################ |
|
FROM golang:alpine AS builder |
|
RUN apk update && apk add --no-cache git bash wget |
|
WORKDIR /go/src/v2ray.com/core |
|
RUN git clone --progress --depth=1 --branch dockerdev https://github.com/v2fly/v2ray-core.git . && \ |
|
bash -x ./release/user-package.sh nosource noconf abpathtgz=/tmp/v2ray.tgz |
|
############################ |
|
# STEP 2 build a small image |
|
############################ |
|
FROM alpine |
|
COPY --from=builder /tmp/v2ray.tgz /tmp |
|
RUN apk update && apk add ca-certificates && \ |
|
mkdir -p /usr/bin/v2ray && \ |
|
tar xvfz /tmp/v2ray.tgz -C /usr/bin/v2ray |
|
ENTRYPOINT ["/usr/bin/v2ray/v2ray"]
|
|
|