| |
| |
| |
| |
|
|
| version: '3.8' |
|
|
| services: |
| valentine-app: |
| build: |
| context: . |
| dockerfile: Dockerfile |
| container_name: valentine-experience |
| image: valentine-app:3.0.0 |
| |
| |
| ports: |
| - "8080:8080" |
| |
| |
| environment: |
| - TZ=UTC |
| - NGINX_WORKER_PROCESSES=auto |
| |
| |
| deploy: |
| resources: |
| limits: |
| cpus: '0.5' |
| memory: 256M |
| reservations: |
| cpus: '0.25' |
| memory: 128M |
| |
| |
| restart: unless-stopped |
| |
| |
| healthcheck: |
| test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:8080/health"] |
| interval: 30s |
| timeout: 3s |
| retries: 3 |
| start_period: 5s |
| |
| |
| logging: |
| driver: "json-file" |
| options: |
| max-size: "10m" |
| max-file: "3" |
| |
| |
| security_opt: |
| - no-new-privileges:true |
| |
| |
| read_only: true |
| tmpfs: |
| - /var/cache/nginx:size=10M |
| - /var/run:size=1M |
| - /tmp:size=10M |
| |
| |
| networks: |
| - valentine-network |
|
|
| networks: |
| valentine-network: |
| driver: bridge |
| name: valentine-network |
|
|