Se recurre a usar imagenes pre-compiladas para evitar carga en el
servidor
This commit is contained in:
BIN
builds/unified-restaurant-backend.tar.gz
Normal file
BIN
builds/unified-restaurant-backend.tar.gz
Normal file
Binary file not shown.
BIN
builds/unified-restaurant-frontend.tar.gz
Normal file
BIN
builds/unified-restaurant-frontend.tar.gz
Normal file
Binary file not shown.
@@ -2,16 +2,12 @@ version: "3.9"
|
||||
|
||||
services:
|
||||
backend:
|
||||
build:
|
||||
context: ./backend
|
||||
dockerfile: ./Dockerfile.prod
|
||||
image: unified-restaurant-backend
|
||||
ports:
|
||||
- 8080:8080
|
||||
|
||||
frontend:
|
||||
build:
|
||||
context: ./frontend
|
||||
dockerfile: ./Dockerfile.prod
|
||||
image: unified-restaurant-frontend
|
||||
ports:
|
||||
- 4200:80
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ WORKDIR /angular
|
||||
COPY package.json package-lock.json /angular/
|
||||
RUN npm install
|
||||
COPY . /angular
|
||||
RUN npm run prod
|
||||
RUN npm run build
|
||||
|
||||
FROM nginx:stable-alpine
|
||||
COPY --from=build /angular/dist/frontend /usr/share/nginx/html
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
"start": "ng serve --host 0.0.0.0",
|
||||
"build": "ng build",
|
||||
"watch": "ng build --watch --configuration development",
|
||||
"prod": "node --max_old_space_size=500 ./node_modules/@angular/cli/bin/ng build",
|
||||
"test": "ng test"
|
||||
},
|
||||
"private": true,
|
||||
|
||||
Reference in New Issue
Block a user