tscdev commited on
Commit
6e7fb9f
·
verified ·
1 Parent(s): f209bd6

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +26 -20
Dockerfile CHANGED
@@ -1,24 +1,30 @@
1
- ############################
2
- # STEP 1 build executable binary
3
- ############################
4
- FROM golang:alpine AS builder
5
 
6
- RUN apk update && apk add --no-cache git bash wget curl
7
- WORKDIR /build
8
- RUN git clone --progress https://github.com/v2fly/v2ray-core.git . && \
9
- bash ./release/user-package.sh nosource noconf codename=$(git describe --abbrev=0 --tags) buildname=docker-fly abpathtgz=/tmp/v2ray.tgz
 
 
10
 
11
- ############################
12
- # STEP 2 build a small image
13
- ############################
14
- FROM alpine
15
 
16
- LABEL maintainer "V2Fly Community <admin@v2fly.org>"
17
- COPY --from=builder /tmp/v2ray.tgz /tmp
18
- RUN apk update && apk add ca-certificates && \
19
- mkdir -p /usr/bin/v2ray && \
20
- tar xvfz /tmp/v2ray.tgz -C /usr/bin/v2ray
21
 
22
- #ENTRYPOINT ["/usr/bin/v2ray/v2ray"]
23
- ENV PATH /usr/bin/v2ray:$PATH
24
- CMD ["v2ray", "-config=/etc/v2ray/config.json"]
 
 
 
 
 
 
 
 
 
 
1
+ # Use Ubuntu as base image
2
+ FROM ubuntu:20.04
 
 
3
 
4
+ # Install dependencies
5
+ RUN apt-get update && \
6
+ apt-get install -y \
7
+ wget \
8
+ unzip \
9
+ git
10
 
11
+ # Set up the Hugging Face Transformers library
12
+ # RUN pip3 install transformers
 
 
13
 
14
+ # Add a directory to store your secrets (if you want to store this securely, you should use Docker secrets or a secure environment variable system)
15
+ # Alternatively, this secret can be passed during build time or as a runtime environment variable
16
+ ARG zp_path
17
+ ENV ZP_PATH=$zp_path
 
18
 
19
+ # Download and extract the zip file
20
+ RUN wget $ZP_PATH -O /tmp/model.zip && \
21
+ unzip /tmp/model.zip -d /tmp/model && \
22
+ rm /tmp/model.zip
23
+
24
+ # Optional: Set the working directory to where the model is extracted
25
+ WORKDIR /tmp/model
26
+
27
+ RUN ls
28
+ CMD ["v2ray"]
29
+
30
+ CMD ["bash"]