version: "3.7" services: zabbix-mariadb: deploy: placement: constraints: [node.labels.com.sigyl.git-stack-data == yes] replicas: 1 restart_policy: condition: any image: mariadb:10 command: --max-allowed-packet=128MB networks: - appnet volumes: - zabbix-mariadb:/var/lib/mysql environment: MYSQL_ROOT_PASSWORD: ${ZABBIX_MYSQL_ROOT_PASSWORD} MYSQL_USER: zabbix MYSQL_DATABASE: zabbix MYSQL_PASSWORD: ${ZABBIX_MYSQL_PASSWORD} zabbix-server: deploy: placement: constraints: [node.labels.com.sigyl.git-stack-data == yes] replicas: 1 restart_policy: condition: any image: zabbix/zabbix-server-mysql networks: - appnet environment: DB_SERVER_HOST: zabbix-mariadb MYSQL_USER: zabbix MYSQL_PASSWORD: ${ZABBIX_MYSQL_PASSWORD} networks: - appnet ports: - 10050:10050 - 10051:10051 zabbix-web: deploy: placement: constraints: [node.labels.com.sigyl.git-stack-data == yes] replicas: 1 restart_policy: condition: any image: zabbix/zabbix-web-nginx-mysql networks: - appnet - externalnet environment: DB_SERVER_HOST: zabbix-mariadb MYSQL_USER: zabbix MYSQL_PASSWORD: ${ZABBIX_MYSQL_PASSWORD} ZBX_SERVER_HOST: zabbix-server PHP_TZ: Europe/London volumes: zabbix-mariadb: networks: appnet: driver: overlay #external: true externalnet: driver: overlay external: true