Skip to content
This repository has been archived by the owner on Jun 16, 2021. It is now read-only.

Support for stop_grace_period #447

Closed
procrypt opened this issue Mar 2, 2017 · 2 comments · Fixed by #465
Closed

Support for stop_grace_period #447

procrypt opened this issue Mar 2, 2017 · 2 comments · Fixed by #465

Comments

@procrypt
Copy link

procrypt commented Mar 2, 2017

If my docker-compose file containesstop_grace_period directive I get this error.

$ libcompose up
WARN[0000] Note: This is an experimental alternate implementation of the Compose CLI (https://github.com/docker/compose) 
ERRO[0000] Could not parse config for project komposefiles : Unsupported config option for web service: 'stop_grace_period' 
FATA[0000] Failed to read project: Unsupported config option for web service: 'stop_grace_period'

docker-compose file

version: "2"
services:
  web:
    image: tuna/docker-counter23
    stop_grace_period: 1s
    ports:
      - "5000:5000"
  redis:
    image: redis:3.0
    ports:
      - "6379"
@vdemeester vdemeester modified the milestone: 0.5.0 Tiny Turing Mar 13, 2017
gitlawr added a commit to gitlawr/libcompose that referenced this issue May 4, 2017
fix docker#447
This commit add support for 'stop_grace_period'
The key is available in compose V2 and with docker API
version 1.25+

Signed-off-by: Lawrence Li <[email protected]>
@tirasmuturi
Copy link

You need to check the docker compose version in your docker compose file.
Use version 3 and above.

Use can follow this documentation.
https://docs.docker.com/compose/compose-file/#stop_grace_period

@nebulous
Copy link

I ran into this as well using v2. FWIW, the docs seem to indicate stop_grace_period should work inv2.
https://docs.docker.com/compose/compose-file/compose-file-v2/#stop_grace_period

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants