Aufgrund einer Konfigurationsänderung wird die GitLab Registry ab 10 Uhr nur Read Only zur Verfügung stehen. / Due to a configuration change, the GitLab Registry will be available for read-only access from 10am.

Commit 34f13811 authored by Markus Grigull's avatar Markus Grigull

Fix various errors in deployment

Fix website volume
Update backend submodule
Remove unneeded open ports
parent 3d4d8d10
...@@ -5,15 +5,9 @@ RUN mkdir -p /usr/src/app ...@@ -5,15 +5,9 @@ RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app WORKDIR /usr/src/app
# Install app dependencies # Install app dependencies
COPY package.json /usr/src/app/
RUN npm install
VOLUME /usr/src/app/build
# Bundle app source
COPY . /usr/src/app COPY . /usr/src/app
RUN npm run build RUN npm install && npm run build
EXPOSE 80 VOLUME /usr/src/app/build
CMD [ "npm", "start" ] CMD [ "true" ]
Subproject commit 22e594a848798a79f0ab90e6e0a6ff2fe3d91e8b Subproject commit c3bbf18279b892374c8998a455d57ec8acc92501
...@@ -3,9 +3,7 @@ version: "2" ...@@ -3,9 +3,7 @@ version: "2"
volumes: volumes:
database: database:
driver: local driver: local
website:
networks:
villas:
services: services:
# Build the frontend with node into a Docker volume # Build the frontend with node into a Docker volume
...@@ -14,7 +12,8 @@ services: ...@@ -14,7 +12,8 @@ services:
frontend: frontend:
build: build:
context: . context: .
command: "/bin/true" volumes:
- website:/usr/src/app/build
nginx: nginx:
build: build:
...@@ -23,10 +22,8 @@ services: ...@@ -23,10 +22,8 @@ services:
ports: ports:
- "80:80" - "80:80"
- "443:443" - "443:443"
volumes_from: volumes:
- frontend - website:/www
networks:
villas:
# The VILLASweb backend # The VILLASweb backend
backend: backend:
...@@ -34,8 +31,6 @@ services: ...@@ -34,8 +31,6 @@ services:
environment: environment:
- NODE_ENV=production - NODE_ENV=production
restart: always restart: always
networks:
villas:
# The MongoDB database for the VILLASweb backend # The MongoDB database for the VILLASweb backend
database: database:
...@@ -43,12 +38,8 @@ services: ...@@ -43,12 +38,8 @@ services:
user: mongodb user: mongodb
volumes: volumes:
- database:/data/db - database:/data/db
expose:
- "27017"
restart: always restart: always
user: mongodb user: mongodb
networks:
villas:
# AMQP broker for VILLAScontroller # AMQP broker for VILLAScontroller
# broker: # broker:
...@@ -70,5 +61,3 @@ services: ...@@ -70,5 +61,3 @@ services:
privileged: true privileged: true
restart: always restart: always
command: node /etc/villas/node/websocket-demo.conf command: node /etc/villas/node/websocket-demo.conf
networks:
villas:
...@@ -27,7 +27,7 @@ server { ...@@ -27,7 +27,7 @@ server {
# frontend location # frontend location
location / { location / {
root /usr/src/app/build/; root /www;
} }
# error pages # error pages
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment