Open rougegoat opened 8 years ago
Yep-that is correct. Promote calls a Policy method named add_package
, which you can see culminates in setting the action to "install" here
I think adding a defaulted argument to add_package
, like def add_package(self, pkg, action="Install"):
and then using that later in the method would solve the python-jss issue.
Then jss_helper could pull the previous policy's existing action and use that in the add_package
call.
I can put these two changes onto the TODO list for the next release.
This was a gotcha when deploying patchoo. Easy enough to work around but would love to be able to tell jss_helper to not change the install method
Some of our policies are cache only. Whenever they are updated through jss_helper, the new package defaults to "Install" rather than whatever state the previous package was in.
It's not really a huge issue, but it would save a few steps on some policy updates.