Kaballas commited on
Commit
5fe1015
·
verified ·
1 Parent(s): 4fcab11

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +32 -37
Dockerfile CHANGED
@@ -1,42 +1,37 @@
1
- # Use the official SQLite Web image as the base image
2
- FROM ghcr.io/coleifer/sqlite-web:latest
3
 
4
- # Set environment variables
5
- ENV STORAGE_DIR="/data/storage"
6
- ENV SERVER_PORT=7860
7
- ENV SQLITE_DATABASE="${STORAGE_DIR}/anythingllm.db"
8
-
9
- # Expose the server port
10
- EXPOSE ${SERVER_PORT}
11
 
12
- # Set the working directory
13
- WORKDIR /data
14
 
 
 
15
  # Create the storage directory and set permissions
16
- RUN mkdir -p ${STORAGE_DIR} && chmod -R 777 ${STORAGE_DIR}
17
-
18
  # Command to run SQLite Web using the correct option for specifying the database file
19
- CMD sqlite_web --host=0.0.0.0 --port=${SERVER_PORT} ${SQLITE_DATABASE}
20
-
21
- #FROM mintplexlabs/anythingllm:render
22
-
23
- #USER root
24
-
25
- ## Create storage directory and link
26
- #RUN mkdir -p /data/storage
27
- #RUN ln -s /data/storage /storage
28
- ## Switch to user for AnythingLLM
29
- #USER anythingllm
30
- ## Set environment variables for storage and server port
31
- #ENV STORAGE_DIR="/data/storage"
32
- #ENV SERVER_PORT=7860
33
- ## Copy the custom script to handle the backup
34
- #COPY copy-storage.sh /usr/local/bin/copy-storage.sh
35
- # Ensure the script has execution permissions
36
- #USER root
37
- #RUN chmod +x /usr/local/bin/copy-storage.sh
38
- ## Switch back to the anythingllm user
39
- #USER anythingllm
40
- # Set the entry point to run the script and the main application
41
- #ENTRYPOINT ["/bin/bash","/usr/local/bin/render-entrypoint.sh"]
42
-
 
1
+ ## Use the official SQLite Web image as the base image
2
+ #FROM ghcr.io/coleifer/sqlite-web:latest
3
 
4
+ ## Set environment variables
5
+ #ENV STORAGE_DIR="/data/storage"
6
+ #ENV SERVER_PORT=7860
7
+ #ENV SQLITE_DATABASE="${STORAGE_DIR}/anythingllm.db"
 
 
 
8
 
9
+ ## Expose the server port
10
+ #EXPOSE ${SERVER_PORT}
11
 
12
+ ## Set the working directory
13
+ #WORKDIR /data
14
  # Create the storage directory and set permissions
15
+ #RUN mkdir -p ${STORAGE_DIR} && chmod -R 777 ${STORAGE_DIR}
 
16
  # Command to run SQLite Web using the correct option for specifying the database file
17
+ #CMD sqlite_web --host=0.0.0.0 --port=${SERVER_PORT} ${SQLITE_DATABASE}
18
+
19
+ FROM mintplexlabs/anythingllm:render
20
+ USER root
21
+ # Create storage directory and link
22
+ RUN mkdir -p /data/storage
23
+ RUN ln -s /data/storage /storage
24
+ # Switch to user for AnythingLLM
25
+ USER anythingllm
26
+ # Set environment variables for storage and server port
27
+ ENV STORAGE_DIR="/data/storage"
28
+ ENV SERVER_PORT=7860
29
+ # Copy the custom script to handle the backup
30
+ COPY copy-storage.sh /usr/local/bin/copy-storage.sh
31
+ Ensure the script has execution permissions
32
+ USER root
33
+ RUN chmod +x /usr/local/bin/copy-storage.sh
34
+ # Switch back to the anythingllm user
35
+ USER anythingllm
36
+ Set the entry point to run the script and the main application
37
+ ENTRYPOINT ["/bin/bash","/usr/local/bin/render-entrypoint.sh"]