Generate no cidfile by default, even when deploying as service.#172
Merged
Conversation
|
I seem to be having lots of issues with cidfiles also. Even with the 0.35.0 update yesterday that addressed some of the cid issues I am still having to manually delete cidfiles |
|
+1 on disable cidfile by default, it's really annoying. I need to delete it every time before running a container, otherwise it will simply fail. |
Contributor
|
Personally I'm a fan of removing the cidfiles as well. They are more trouble than they are worth it seems. I'll merge this in and refactor the now extraneous cidfile method out. |
bflad
added a commit
that referenced
this pull request
Jun 26, 2014
Generate no cidfile by default, even when deploying as service.
Contributor
Author
|
Thank you @bflad for the quick merge! I didn't refactor out the |
|
Awesome, redeploy works great now! |
Contributor
|
🎉 sweet! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR remove the default value of
/var/run/#{service_name}.cidwhen deploying container as a service. In other words, this means that containers will be deployed without a cidfile unless docker_container is configured with an explicit value for its cidfile attribute.The main reason for that (slightly breaking) change is that :
/var/runwhich is flushed at every reboot (tmpfs)docker startwon't recreate cidfiles (onlydocker run --cidfilewill)My conclusion is that since the cidfiles we generate in
/var/rundo not survive reboots they cannot be relied upon and should not be generated by default.My other reasons:
fgrep -r cidshows that no code depends on them in the cookbook)docker runwon't recreate a named container when there is a stale cidfile, see Removing a container should also remove its cidfile. #164)In the past I hacked around the cidfile issue by configuring my docker_container resources with
cidfile ''but recent dockers (post 0.9) choke whendocker runis invoked with--cidfile=''.