Update Dockerfile
Browse files- Dockerfile +26 -20
Dockerfile
CHANGED
|
@@ -1,24 +1,30 @@
|
|
| 1 |
-
#
|
| 2 |
-
|
| 3 |
-
############################
|
| 4 |
-
FROM golang:alpine AS builder
|
| 5 |
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
|
|
|
|
|
|
| 10 |
|
| 11 |
-
#
|
| 12 |
-
#
|
| 13 |
-
############################
|
| 14 |
-
FROM alpine
|
| 15 |
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
tar xvfz /tmp/v2ray.tgz -C /usr/bin/v2ray
|
| 21 |
|
| 22 |
-
#
|
| 23 |
-
|
| 24 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 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"]
|