version: "3.2" services: web: image: busybox deploy: mode: replicated replicas: 6 labels: [FOO=BAR] update_config: parallelism: 3 delay: 10s failure_action: continue monitor: 60s max_failure_ratio: 0.3 resources: limits: cpus: '0.001' memory: 50M reservations: cpus: '0.0001' memory: 20M restart_policy: condition: on_failure delay: 5s max_attempts: 3 window: 120s placement: constraints: [node=foo] healthcheck: test: cat /etc/passwd interval: 10s timeout: 1s retries: 5 volumes: - source: /host/path target: /container/path type: bind read_only: true - source: foobar type: volume target: /container/volumepath - type: volume target: /anonymous - type: volume source: foobar target: /container/volumepath2 volume: nocopy: true stop_grace_period: 20s volumes: foobar: labels: com.docker.compose.test: 'true'