aggiunto supporto per il ridimensionamento della finestra e configurazione Docker per il deployment
Some checks are pending
Deploy in Produzione / deploy (push) Waiting to run
Some checks are pending
Deploy in Produzione / deploy (push) Waiting to run
This commit is contained in:
17
Dockerfile
Normal file
17
Dockerfile
Normal file
@@ -0,0 +1,17 @@
|
||||
# FASE 1: Build (Node.js)
|
||||
FROM node:lts-alpine as build-stage
|
||||
WORKDIR /app
|
||||
COPY package*.json ./
|
||||
RUN npm install
|
||||
COPY . .
|
||||
# Verifica che il comando nel package.json sia "build"
|
||||
RUN npm run build
|
||||
|
||||
# FASE 2: Produzione (Nginx)
|
||||
FROM nginx:stable-alpine as production-stage
|
||||
# Copia la configurazione custom di Nginx (vedi file successivo)
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
# Copia i file compilati dalla cartella dist (di solito è /dist)
|
||||
COPY --from=build-stage /app/dist /usr/share/nginx/html
|
||||
EXPOSE 80
|
||||
CMD ["nginx", "-g", "daemon off;"]
|
||||
Reference in New Issue
Block a user