wuhunfeng77 commited on
Commit
98b78eb
·
verified ·
1 Parent(s): 59a4cdd

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +27 -0
Dockerfile ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM eclipse-temurin:17-jre
2
+
3
+ WORKDIR /opt/halo
4
+
5
+ ENV TZ=Asia/Shanghai
6
+ ENV JVM_OPTS="-Xmx256m -Xms256m"
7
+
8
+ RUN apt-get update && \
9
+ apt-get install -y wget python3 python3-venv python3-pip tar gzip && \
10
+ apt-get clean && \
11
+ rm -rf /var/lib/apt/lists/*
12
+
13
+ RUN wget https://dl.halo.run/release/halo-2.12.0.jar -O halo.jar
14
+
15
+ RUN mkdir -p ~/.halo2
16
+
17
+ ENV VIRTUAL_ENV=/opt/venv
18
+ RUN python3 -m venv $VIRTUAL_ENV
19
+ ENV PATH="$VIRTUAL_ENV/bin:$PATH"
20
+ RUN pip install --no-cache-dir huggingface_hub
21
+
22
+ COPY sync_data.sh /opt/halo/
23
+ RUN chmod +x /opt/halo/sync_data.sh
24
+
25
+ EXPOSE 8090
26
+
27
+ CMD ["/bin/sh", "-c", "/opt/halo/sync_data.sh"]