Update Dockerfile
Browse files- Dockerfile +13 -4
Dockerfile
CHANGED
@@ -13,8 +13,17 @@ RUN npm install
|
|
13 |
# Copy the rest of the application code
|
14 |
COPY . .
|
15 |
|
16 |
-
#
|
17 |
-
|
18 |
|
19 |
-
#
|
20 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
# Copy the rest of the application code
|
14 |
COPY . .
|
15 |
|
16 |
+
# Install Nginx
|
17 |
+
RUN apt-get update && apt-get install -y nginx
|
18 |
|
19 |
+
# Remove the default Nginx configuration file
|
20 |
+
RUN rm /etc/nginx/sites-enabled/default
|
21 |
+
|
22 |
+
# Copy your Nginx configuration
|
23 |
+
COPY nginx.conf /etc/nginx/sites-enabled/
|
24 |
+
|
25 |
+
# Expose both ports: one for Nginx and one for WebSocket
|
26 |
+
EXPOSE 80 6060
|
27 |
+
|
28 |
+
# Start both Nginx and Node.js backend
|
29 |
+
CMD service nginx start && node server.js
|