Add deploy.sh

This commit is contained in:
2026-06-01 16:33:19 -05:00
parent 7777df6a83
commit 2bb0cc6b94
2 changed files with 50 additions and 14 deletions
+6 -14
View File
@@ -1,17 +1,9 @@
FROM docker.io/nginx:alpine
FROM alpine:latest
# Remove default nginx static assets
RUN rm -rf /usr/share/nginx/html/*
WORKDIR /app
# Copy landing page files to nginx web root
COPY index.html /usr/share/nginx/html/
COPY styles.css /usr/share/nginx/html/
COPY script.js /usr/share/nginx/html/
COPY media /usr/share/nginx/html/media
# El script le pasará los archivos clonados a esta carpeta
COPY . /app
# Optional: custom nginx config for SPA or security headers
# COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 8090
CMD ["nginx", "-g", "daemon off;"]
# Al arrancar, el contenedor vacía el volumen compartido y copia los archivos nuevos
CMD rm -rf /publico/* && cp -r ./* /publico/ && echo "✅ Sitio web actualizado con éxito."