镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

Backup and restore all HostConfig settings - #22

Open
andrewleech wants to merge 1 commit into
muesli:masterfrom
andrewleech:hostconfig
Open

andrewleech wants to merge 1 commit into
muesli:masterfrom
andrewleech:hostconfig

Conversation

@andrewleech

Copy link
Copy Markdown

This ensures new container has all the existing settings like bind mount paths, RestartPolicy, Privileged, etc.

This ensures new container has all the existing settings like bind mount paths, RestartPolicy, Privileged, etc.
@muesli

muesli commented Apr 28, 2021

Copy link
Copy Markdown
Owner

This looks good and should probably be the default, but I wonder if we shouldn't allow to optionally turn this off. I'm a bit worried there may be various situations where the original host config doesn't fully apply to the new container. We could look at the list of HostConfig members and identify problematic candidates.

@andrewleech

Copy link
Copy Markdown
Author

Yeah that's a good point. While there are a lot of keys I ended up needing in HostConfig, there are even more I never even tried to figure out the function of. There probably are a likely set of keys that don't make sense to store, especially for cases where you're restoring on a different host.

I think the safest option is to backup all of these keys (then there's no regret later from not having information you find you need), but then having a way to choose / filter what gets restored, or at least having a pre-set list of keys to restore that should work in most/all cases.

@muesli

muesli commented Apr 30, 2021

Copy link
Copy Markdown
Owner

I think the safest option is to backup all of these keys (then there's no regret later from not having information you find you need), but then having a way to choose / filter what gets restored, or at least having a pre-set list of keys to restore that should work in most/all cases.

I fully agree!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants