Loading .gitlab-ci.yml +5 −9 Original line number Diff line number Diff line Loading @@ -12,7 +12,7 @@ variables: DEPLOY_DIR_NAME: '.' STATUS_CHECK_DELAY: 60 STACK: metric SERVICES_TO_CHECK: metric_dockerd-exporter metric_cadvisor metric_grafana metric_alertmanager metric_unsee metric_node-exporter metric_pushgateway SERVICES_TO_CHECK: metric_dockerd-exporter metric_cadvisor metric_alertmanager metric_unsee metric_node-exporter metric_pushgateway deploy-supporting-branch-develop: stage: deploy Loading @@ -22,8 +22,7 @@ deploy-supporting-branch-develop: PUBLIC_HOSTNAME: ${DEV_PUBLIC_HOSTNAME} script: - > deploy.sh COMPOSE_FILE=${COMPOSE_FILE} ADMIN_USER=${ADMIN_USER} ADMIN_PASSWORD=${ADMIN_PASSWORD} DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} deploy.sh DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} SLACK_URL=${SLACK_URL} SLACK_CHANNEL=${SLACK_CHANNEL} SLACK_USER=${SLACK_USER} environment: name: dev Loading @@ -41,8 +40,7 @@ deploy-stable-branch-develop: PUBLIC_HOSTNAME: ${DEV_PUBLIC_HOSTNAME} script: - > deploy.sh COMPOSE_FILE=${COMPOSE_FILE} ADMIN_USER=${ADMIN_USER} ADMIN_PASSWORD=${ADMIN_PASSWORD} DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} deploy.sh DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} SLACK_URL=${SLACK_URL} SLACK_CHANNEL=${SLACK_CHANNEL} SLACK_USER=${SLACK_USER} environment: name: dev Loading @@ -58,8 +56,7 @@ deploy-supporting-branch-production: PUBLIC_HOSTNAME: ${PRO_PUBLIC_HOSTNAME} script: - > deploy.sh COMPOSE_FILE=${COMPOSE_FILE} ADMIN_USER=${ADMIN_USER} ADMIN_PASSWORD=${ADMIN_PASSWORD} DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} deploy.sh DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} SLACK_URL=${SLACK_URL} SLACK_CHANNEL=${SLACK_CHANNEL} SLACK_USER=${SLACK_USER} environment: name: pro Loading @@ -77,8 +74,7 @@ deploy-stable-branch-production: PUBLIC_HOSTNAME: ${PRO_PUBLIC_HOSTNAME} script: - > deploy.sh COMPOSE_FILE=${COMPOSE_FILE} ADMIN_USER=${ADMIN_USER} ADMIN_PASSWORD=${ADMIN_PASSWORD} DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} deploy.sh DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} SLACK_URL=${SLACK_URL} SLACK_CHANNEL=${SLACK_CHANNEL} SLACK_USER=${SLACK_USER} environment: name: pro Loading docker-compose.dev.yml +9 −3 Original line number Diff line number Diff line version: '3.5' volumes: grafana: name: ${GRAFANA_VOL_NAME:-grafana-vol} services: cadvisor: deploy: resources: limits: cpus: '0.5' memory: 512M reservations: memory: 256M docker-compose.prod.yml +7 −11 Original line number Diff line number Diff line version: '3.5' services: grafana: cadvisor: deploy: placement: constraints: - node.role == manager resources: limits: cpus: '0.5' memory: 256M reservations: memory: 128M pushgateway: deploy: placement: constraints: - node.role == worker volumes: grafana: name: ${GRAFANA_VOL_NAME:-grafana-vol} driver: 'cloudstor:aws' driver_opts: backing: shared docker-compose.tmpl.yml +10 −52 Original line number Diff line number Diff line Loading @@ -19,10 +19,10 @@ services: window: 1m resources: limits: cpus: '0.5' memory: 128M cpus: '0.1' memory: 32M reservations: memory: 16M memory: 8M cadvisor: image: google/cadvisor Loading @@ -46,48 +46,6 @@ services: restart_policy: delay: 30s window: 1m resources: limits: cpus: '1' memory: 256M reservations: memory: 64M grafana: image: stefanprodan/swarmprom-grafana:5.3.4 environment: - GF_SECURITY_ADMIN_USER=${ADMIN_USER:-admin} - GF_SECURITY_ADMIN_PASSWORD=${ADMIN_PASSWORD:-admin} - GF_USERS_ALLOW_SIGN_UP=false - GF_INSTALL_PLUGINS=grafana-clock-panel,grafana-piechart-panel #- GF_SERVER_ROOT_URL=${GF_SERVER_ROOT_URL:-localhost} #- GF_SMTP_ENABLED=${GF_SMTP_ENABLED:-false} #- GF_SMTP_FROM_ADDRESS=${GF_SMTP_FROM_ADDRESS:-grafana@test.com} #- GF_SMTP_FROM_NAME=${GF_SMTP_FROM_NAME:-Grafana} #- GF_SMTP_HOST=${GF_SMTP_HOST:-smtp:25} #- GF_SMTP_USER=${GF_SMTP_USER} #- GF_SMTP_PASSWORD=${GF_SMTP_PASSWORD} networks: - metric-net - traefik-net volumes: - grafana:/var/lib/grafana deploy: mode: replicated replicas: 1 labels: traefik.frontend.rule: Host:grafana.${PUBLIC_HOSTNAME} traefik.backend: grafana traefik.port: '3000' restart_policy: delay: 1m window: 3m resources: limits: cpus: '1' memory: 128M reservations: memory: 64M alertmanager: image: stefanprodan/swarmprom-alertmanager:v0.14.0 Loading Loading @@ -119,8 +77,8 @@ services: window: 1m resources: limits: cpus: '0.5' memory: 128M cpus: '0.1' memory: 64M reservations: memory: 32M Loading @@ -144,8 +102,8 @@ services: window: 1m resources: limits: cpus: '0.5' memory: 128M cpus: '0.1' memory: 64M reservations: memory: 32M Loading Loading @@ -173,8 +131,8 @@ services: window: 1m resources: limits: cpus: '0.5' memory: 128M cpus: '0.1' memory: 64M reservations: memory: 32M Loading @@ -200,7 +158,7 @@ services: window: 1m resources: limits: cpus: '0.5' cpus: '0.1' memory: 64M reservations: memory: 16M Loading Loading
.gitlab-ci.yml +5 −9 Original line number Diff line number Diff line Loading @@ -12,7 +12,7 @@ variables: DEPLOY_DIR_NAME: '.' STATUS_CHECK_DELAY: 60 STACK: metric SERVICES_TO_CHECK: metric_dockerd-exporter metric_cadvisor metric_grafana metric_alertmanager metric_unsee metric_node-exporter metric_pushgateway SERVICES_TO_CHECK: metric_dockerd-exporter metric_cadvisor metric_alertmanager metric_unsee metric_node-exporter metric_pushgateway deploy-supporting-branch-develop: stage: deploy Loading @@ -22,8 +22,7 @@ deploy-supporting-branch-develop: PUBLIC_HOSTNAME: ${DEV_PUBLIC_HOSTNAME} script: - > deploy.sh COMPOSE_FILE=${COMPOSE_FILE} ADMIN_USER=${ADMIN_USER} ADMIN_PASSWORD=${ADMIN_PASSWORD} DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} deploy.sh DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} SLACK_URL=${SLACK_URL} SLACK_CHANNEL=${SLACK_CHANNEL} SLACK_USER=${SLACK_USER} environment: name: dev Loading @@ -41,8 +40,7 @@ deploy-stable-branch-develop: PUBLIC_HOSTNAME: ${DEV_PUBLIC_HOSTNAME} script: - > deploy.sh COMPOSE_FILE=${COMPOSE_FILE} ADMIN_USER=${ADMIN_USER} ADMIN_PASSWORD=${ADMIN_PASSWORD} DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} deploy.sh DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} SLACK_URL=${SLACK_URL} SLACK_CHANNEL=${SLACK_CHANNEL} SLACK_USER=${SLACK_USER} environment: name: dev Loading @@ -58,8 +56,7 @@ deploy-supporting-branch-production: PUBLIC_HOSTNAME: ${PRO_PUBLIC_HOSTNAME} script: - > deploy.sh COMPOSE_FILE=${COMPOSE_FILE} ADMIN_USER=${ADMIN_USER} ADMIN_PASSWORD=${ADMIN_PASSWORD} DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} deploy.sh DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} SLACK_URL=${SLACK_URL} SLACK_CHANNEL=${SLACK_CHANNEL} SLACK_USER=${SLACK_USER} environment: name: pro Loading @@ -77,8 +74,7 @@ deploy-stable-branch-production: PUBLIC_HOSTNAME: ${PRO_PUBLIC_HOSTNAME} script: - > deploy.sh COMPOSE_FILE=${COMPOSE_FILE} ADMIN_USER=${ADMIN_USER} ADMIN_PASSWORD=${ADMIN_PASSWORD} DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} deploy.sh DOCKER_GWBRIDGE_IP=${DOCKER_GWBRIDGE_IP} UI_AUTH=${UI_AUTH} PUBLIC_HOSTNAME=${PUBLIC_HOSTNAME} SLACK_URL=${SLACK_URL} SLACK_CHANNEL=${SLACK_CHANNEL} SLACK_USER=${SLACK_USER} environment: name: pro Loading
docker-compose.dev.yml +9 −3 Original line number Diff line number Diff line version: '3.5' volumes: grafana: name: ${GRAFANA_VOL_NAME:-grafana-vol} services: cadvisor: deploy: resources: limits: cpus: '0.5' memory: 512M reservations: memory: 256M
docker-compose.prod.yml +7 −11 Original line number Diff line number Diff line version: '3.5' services: grafana: cadvisor: deploy: placement: constraints: - node.role == manager resources: limits: cpus: '0.5' memory: 256M reservations: memory: 128M pushgateway: deploy: placement: constraints: - node.role == worker volumes: grafana: name: ${GRAFANA_VOL_NAME:-grafana-vol} driver: 'cloudstor:aws' driver_opts: backing: shared
docker-compose.tmpl.yml +10 −52 Original line number Diff line number Diff line Loading @@ -19,10 +19,10 @@ services: window: 1m resources: limits: cpus: '0.5' memory: 128M cpus: '0.1' memory: 32M reservations: memory: 16M memory: 8M cadvisor: image: google/cadvisor Loading @@ -46,48 +46,6 @@ services: restart_policy: delay: 30s window: 1m resources: limits: cpus: '1' memory: 256M reservations: memory: 64M grafana: image: stefanprodan/swarmprom-grafana:5.3.4 environment: - GF_SECURITY_ADMIN_USER=${ADMIN_USER:-admin} - GF_SECURITY_ADMIN_PASSWORD=${ADMIN_PASSWORD:-admin} - GF_USERS_ALLOW_SIGN_UP=false - GF_INSTALL_PLUGINS=grafana-clock-panel,grafana-piechart-panel #- GF_SERVER_ROOT_URL=${GF_SERVER_ROOT_URL:-localhost} #- GF_SMTP_ENABLED=${GF_SMTP_ENABLED:-false} #- GF_SMTP_FROM_ADDRESS=${GF_SMTP_FROM_ADDRESS:-grafana@test.com} #- GF_SMTP_FROM_NAME=${GF_SMTP_FROM_NAME:-Grafana} #- GF_SMTP_HOST=${GF_SMTP_HOST:-smtp:25} #- GF_SMTP_USER=${GF_SMTP_USER} #- GF_SMTP_PASSWORD=${GF_SMTP_PASSWORD} networks: - metric-net - traefik-net volumes: - grafana:/var/lib/grafana deploy: mode: replicated replicas: 1 labels: traefik.frontend.rule: Host:grafana.${PUBLIC_HOSTNAME} traefik.backend: grafana traefik.port: '3000' restart_policy: delay: 1m window: 3m resources: limits: cpus: '1' memory: 128M reservations: memory: 64M alertmanager: image: stefanprodan/swarmprom-alertmanager:v0.14.0 Loading Loading @@ -119,8 +77,8 @@ services: window: 1m resources: limits: cpus: '0.5' memory: 128M cpus: '0.1' memory: 64M reservations: memory: 32M Loading @@ -144,8 +102,8 @@ services: window: 1m resources: limits: cpus: '0.5' memory: 128M cpus: '0.1' memory: 64M reservations: memory: 32M Loading Loading @@ -173,8 +131,8 @@ services: window: 1m resources: limits: cpus: '0.5' memory: 128M cpus: '0.1' memory: 64M reservations: memory: 32M Loading @@ -200,7 +158,7 @@ services: window: 1m resources: limits: cpus: '0.5' cpus: '0.1' memory: 64M reservations: memory: 16M Loading