chore: script de démarrage business et export des ENV au runtime
This commit is contained in:
@@ -23,6 +23,7 @@ RUN npm install gray-matter glob
|
||||
|
||||
# Copie du reste du projet
|
||||
COPY . .
|
||||
RUN chmod +x scripts/start-business.sh
|
||||
|
||||
# --- CONFIGURATION BUSINESS ---
|
||||
# Application de la logique Business (remplacement de la config et des données)
|
||||
@@ -33,5 +34,5 @@ RUN cp radar-business/config-business.json config.json && \
|
||||
# Exposition du port interne
|
||||
EXPOSE 3000
|
||||
|
||||
# Démarrage du serveur
|
||||
CMD ["npm", "run", "serve", "--", "--port", "3000"]
|
||||
# Démarrage du serveur via script (exporte les variables avant npm run serve)
|
||||
CMD ["./scripts/start-business.sh"]
|
||||
|
||||
8
scripts/start-business.sh
Normal file
8
scripts/start-business.sh
Normal file
@@ -0,0 +1,8 @@
|
||||
#!/bin/sh
|
||||
|
||||
export HUSKY=0
|
||||
export HUSKY_SKIP_INSTALL=1
|
||||
export NODE_PATH=/app/node_modules
|
||||
|
||||
npm run serve -- --port "${PORT:-3000}"
|
||||
|
||||
Reference in New Issue
Block a user