Hello,
I'd like to monitor a basic docker container with nginx but when I start the zabbix_agentd, my nginx service stop, and I don't understand why ...
Can you help me or explain me the problem ?
When I don't start the agent in Dockerfile, i can start it without killing nginx, with docker exec
Here is my docker-compose :
And my Dockerfile:
I'd like to monitor a basic docker container with nginx but when I start the zabbix_agentd, my nginx service stop, and I don't understand why ...
Can you help me or explain me the problem ?
When I don't start the agent in Dockerfile, i can start it without killing nginx, with docker exec
Here is my docker-compose :
Code:
version: "3.9"
services:
web:
build:
context: .
dockerfile: Dockerfile
restart: always
container_name: webginx
volumes:
- /home/user/nginx/index.html:/var/www/html/index.html
- /home/user/nginx/zabbix_agentd.conf:/etc/zabbix/zabbix_agentd.conf
ports:
- "8000:80"
- "10051:10051"
And my Dockerfile:
Code:
# info version FROM nginx:latest #Full update RUN apt update && apt upgrade -y #Install package RUN apt install -y procps\ && apt install -y zabbix-agent #config zabbix CMD ["su", "zabbix", "-s", "/bin/bash", "-c", "/usr/sbin/zabbix_agentd -f"]