version: "3.8" services: nginx: image: nginx:alpine ports: - "80:80" - "443:443" volumes: - ./default.conf:/etc/nginx/conf.d/default.conf:ro - ./ssl:/etc/nginx/ssl:ro restart: always depends_on: - certbot certbot: image: certbot/certbot:latest volumes: - ./ssl:/etc/letsencrypt - ./certbot-webroot:/var/www/certbot command: certonly --webroot --webroot-path=/var/www/certbot --email admin@ro-being.com --agree-tos --no-eff-email -d ro-being.com restart: "no"