-
Notifications
You must be signed in to change notification settings - Fork 420
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
Remove "source" comments from Saltify configs #316
Remove "source" comments from Saltify configs #316
Conversation
I use Salt environments to provide each of my team mates the ability to develop and test their Salt changes. And I've found that when we run this formula from our environments against our salt-master, comments in some files change. For us this represents an unwanted and unplanned change. I understand the intention - to identify how or why the file changed, but I firmly believe that we should be able to run highstsate with test=True and only see intended changes. Here's an example: ID: salt-cloud-providers Function: file.recurse Name: /etc/salt/cloud.providers.d Result: None Comment: #### /etc/salt/cloud.providers.d/saltify.conf #### The file /etc/salt/cloud.providers.d/saltify.conf is set to be changed Started: 20:01:28.586441 Duration: 75.185 ms Changes: ---------- /etc/salt/cloud.providers.d/saltify.conf: ---------- diff: --- +++ @@ -1,4 +1,4 @@ -# This file is managed by Salt via salt://salt/files/cloud.providers.d/saltify.conf?saltenv=myenv +# This file is managed by Salt via salt://salt/files/cloud.providers.d/saltify.conf?saltenv=dev saltify: provider: saltify
I would suggest to introduce a pillar-based config option to omit those comments instead of removing a feature I consider very useful. |
Yeah, I understand that point of view. On the other hand, we don't seem to do that anywhere else:
|
Submitted this against the upstream: saltstack-formulas#316 Doing it here on our older version with the restart hack
@0xf10e want to merge this or let it sit? |
I would say it's a feature other formulas are missing then. PS: I shouldn't check.those mails before breakfast… |
@0xf10e I'd like you to go ahead and merge this and if you want a "feature" to be added create a follow-up issue. From my standpoint, I'm fixing a bug by making the formula idempotent and making the code more consistent by following existing patterns. Your idea is good, but it's beyond the scope of this PR. |
Oh, I'm honored you want your PR by me. |
@0xf10e I have a rather extensive salt-formula setup so looking in the config files
see:
some have both
I don't mind removing the
|
OK then. |
I use Salt environments to provide each of my team mates the ability to develop
and test their Salt changes. And I've found that when we run this formula from
our environments against our salt-master, comments in some files change. For us
this represents an unwanted and unplanned change. I understand the intention -
to identify whow or why the file changed, but I firmly believe that we should
be able to run highstsate with test=True and only see intended changes. Here's
an example: