Update Dockerfile
Browse files- Dockerfile +1 -11
Dockerfile
CHANGED
|
@@ -1,19 +1,11 @@
|
|
| 1 |
-
# Use an official Node.js image as the base
|
| 2 |
FROM node:18
|
| 3 |
|
| 4 |
-
# Set the working directory
|
| 5 |
WORKDIR /app
|
| 6 |
|
| 7 |
-
|
| 8 |
-
COPY package.json ./
|
| 9 |
|
| 10 |
-
# Install dependencies
|
| 11 |
RUN yarn install
|
| 12 |
|
| 13 |
-
# Copy the entire project into the container
|
| 14 |
-
COPY . .
|
| 15 |
-
|
| 16 |
-
# Set permissions for the entire project and specific files/directories
|
| 17 |
RUN chmod -R 777 /app \
|
| 18 |
&& chmod -R 777 /app/session \
|
| 19 |
&& chmod 666 /app/messages.json \
|
|
@@ -23,8 +15,6 @@ RUN chmod -R 777 /app \
|
|
| 23 |
&& chmod +x /app/Temp \
|
| 24 |
&& chmod +x /app/uploads
|
| 25 |
|
| 26 |
-
# Expose the desired port (adjust as needed)
|
| 27 |
EXPOSE 7860
|
| 28 |
|
| 29 |
-
# Start the application using start.sh
|
| 30 |
CMD ["bash", "./start.sh"]
|
|
|
|
|
|
|
| 1 |
FROM node:18
|
| 2 |
|
|
|
|
| 3 |
WORKDIR /app
|
| 4 |
|
| 5 |
+
RUN git clone <REPO_URL> .
|
|
|
|
| 6 |
|
|
|
|
| 7 |
RUN yarn install
|
| 8 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
RUN chmod -R 777 /app \
|
| 10 |
&& chmod -R 777 /app/session \
|
| 11 |
&& chmod 666 /app/messages.json \
|
|
|
|
| 15 |
&& chmod +x /app/Temp \
|
| 16 |
&& chmod +x /app/uploads
|
| 17 |
|
|
|
|
| 18 |
EXPOSE 7860
|
| 19 |
|
|
|
|
| 20 |
CMD ["bash", "./start.sh"]
|