Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dockerng ] Detect settings removal #31326

Merged

Conversation

ticosax
Copy link
Contributor

@ticosax ticosax commented Feb 18, 2016

When removing settings from dockerng.running state definition,
changes where ignored as _compare() was iterating only over user defined
parameters.

By looping over all available options we are now sure to not miss
removed entries.

Extend definition of expected default values:

  • Some default values are predictable and hardcoded in the VALID_CREATE_OPTS dict.
  • Some default needs to be read from images (image_path)
  • Some defaults values are unpredictable (hostname, mac_address)
    we are comparing desired value against value reported by the container
    (get_default_from_container).

/cc @terminalmage

When removing settings from dockerng.running state definition,
changes where ignored as `_compare()` was iterating only over user defined
parameters.

By looping over all available options we are now sure to not miss
removed entries.

Extend definition of expected default values:

 - Some default values are predictable and hardcoded in the VALID_CREATE_OPTS dict.
 - Some default needs to be read from images (`image_path`)
 - Some defaults values are unpredictable (hostname, mac_address)
 we are comparing desired value against value reported by the container
 (`get_default_from_container`).
cachedout pushed a commit that referenced this pull request Feb 18, 2016
…s-removal

[dockerng ] Detect settings removal
@cachedout cachedout merged commit f0ba9c1 into saltstack:2015.8 Feb 18, 2016
ticosax added a commit to ticosax/salt that referenced this pull request Feb 19, 2016
ports will most likely be defined as integer
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.

None yet

2 participants