
Séparation des scripts de génération et amélioration de l'architecture - Séparé generate_grafana_dashboards.sh en 3 scripts distincts : * generate_grafana_dashboards.sh (dashboards uniquement) * generate_promtail_config.sh (configuration Promtail) * generate_logrotate_configs.sh (configurations Logrotate) - Supprimé generate_docker_compose.sh et generate_docker_variables.sh - Centralisé la génération des variables dans generate_variables.sh - Mis à jour generate.sh pour une architecture en 5 étapes - Corrigé les chemins de sortie et les références de variables - Ajouté la gestion d'erreurs pour les fichiers .env problématiques - Généré toutes les configurations Nginx, Grafana, Promtail et Logrotate - Amélioré la modularité et la maintenabilité du code
361 lines
11 KiB
Plaintext
361 lines
11 KiB
Plaintext
# Configurations internes générées automatiquement
|
|
# Généré le $(date)
|
|
|
|
|
|
server {
|
|
listen $REDIS_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$REDIS_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$REDIS_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$REDIS_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $POSTGRESQL_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$POSTGRESQL_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$POSTGRESQL_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$POSTGRESQL_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $LOKI_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$LOKI_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$LOKI_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$LOKI_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $PROMTAIL_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$PROMTAIL_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$PROMTAIL_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$PROMTAIL_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $GRAFANA_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$GRAFANA_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$GRAFANA_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$GRAFANA_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $NGNIX_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$NGNIX_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$NGNIX_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$NGNIX_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $TOR_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$TOR_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$TOR_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$TOR_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $_4NK_VAULT_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$_4NK_VAULT_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$_4NK_VAULT_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$_4NK_VAULT_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $BITCOIN_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$BITCOIN_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$BITCOIN_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$BITCOIN_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $BLINDBIT_ORACLE_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$BLINDBIT_ORACLE_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$BLINDBIT_ORACLE_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$BLINDBIT_ORACLE_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $SDK_RELAY_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$SDK_RELAY_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$SDK_RELAY_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$SDK_RELAY_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $SDK_STORAGE_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$SDK_STORAGE_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$SDK_STORAGE_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$SDK_STORAGE_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $IHM_CLIENT_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$IHM_CLIENT_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$IHM_CLIENT_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$IHM_CLIENT_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $_4NK_CERTIFICATOR_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$_4NK_CERTIFICATOR_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$_4NK_CERTIFICATOR_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$_4NK_CERTIFICATOR_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $_4NK_MINER_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$_4NK_MINER_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$_4NK_MINER_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$_4NK_MINER_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $LECOFFRE_FRONT_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$LECOFFRE_FRONT_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$LECOFFRE_FRONT_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$LECOFFRE_FRONT_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen $_4NK_WEB_STATUS_PORT default_server;
|
|
server_name _; # pas d'host requis
|
|
access_log $/home/debian/_4NK_env/DOCKER_GLOBAL_NAME/logs/nginx/$_4NK_WEB_STATUS_int.log app_json;
|
|
|
|
location / {
|
|
proxy_pass http://$_4NK_WEB_STATUS_DOCKER_NAME;
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
}
|
|
|
|
# websocket (si nécessaire)
|
|
location /ws/ {
|
|
proxy_pass http://$_4NK_WEB_STATUS_DOCKER_NAME;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
include $/etc/nginx/conf.d/proxy_headers.conf;
|
|
proxy_read_timeout 3600s;
|
|
}
|
|
}
|