version: "3" services: service.nginx: image: nginx:1.22.1 container_name: nginx ports: - 80:80 - 443:443 volumes: - /home/zkpk/nginx/conf.d:/etc/nginx/conf.d - /home/zkpk/nginx/cert:/etc/nginx/cert - /home/zkpk/nginx/fs:/fs extra_hosts: localhost.com: 172.17.0.1 stdin_open: true tty: true restart: always