VishalMysore commited on
Commit
f6ec5e1
·
verified ·
1 Parent(s): 32e2a14

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +18 -3
Dockerfile CHANGED
@@ -1,10 +1,25 @@
1
  FROM openjdk:18
2
- WORKDIR ai
3
 
4
- ADD easyQServer-0.2.3.jar /ai/easyQServer-0.2.3.jar
 
 
 
 
 
 
 
 
 
 
 
 
5
  EXPOSE 7860
 
 
6
  COPY entrypoint.sh /entrypoint.sh
 
7
  # Make the script executable
8
  RUN chmod +x /entrypoint.sh
 
9
  # Set the entrypoint
10
- ENTRYPOINT ["/entrypoint.sh"]
 
1
  FROM openjdk:18
 
2
 
3
+ # Set working directory
4
+ WORKDIR /ai
5
+
6
+ # Set a build argument for the version (default to 0.2.3)
7
+ ARG VERSION=0.2.3
8
+
9
+ # Set the URL using the version argument
10
+ ARG JAR_URL="https://repo1.maven.org/maven2/io/github/vishalmysore/easyQServer/${VERSION}/easyQServer-${VERSION}.jar"
11
+
12
+ # Download the JAR file using wget and rename it to easyQServer.jar
13
+ RUN wget -O easyQServer.jar ${JAR_URL}
14
+
15
+ # Expose the port
16
  EXPOSE 7860
17
+
18
+ # Copy the entrypoint script to the container
19
  COPY entrypoint.sh /entrypoint.sh
20
+
21
  # Make the script executable
22
  RUN chmod +x /entrypoint.sh
23
+
24
  # Set the entrypoint
25
+ ENTRYPOINT ["/entrypoint.sh"]