On Wednesday, October 2, 2013 at 12:33 PM, Brian Hatfield wrote:
No. I strongly object to this.action :upgrade exists and is sufficient.The question isn't whether action :install and action :upgrade should exist or have different behavior, but rather one of what default is most desirable given the tradeoffs of each. By comparison, the default action on a file is "create" which really means "create_or_update"; you can use action :create_if_missing if you want to avoid updating the files.
If action :install performed upgrades, it would absolutely destroy things, for example running MongoDB using the 10gen repos and having a 2.2 database upgrade to 2.4 behind your back, etc.
The reason we bring this up is the flip side of this coin. If the package in your repo gets updated, then a new machine you bring up with the same recipes will create a different system than your machines you provisioned before the repo update. This seems surprising, no?So the question is one of* user expectations: What should `package "tmux"` do when there's a newer version available?* consistency: Is it weird/confusing that files get updated by default, but packages do not? Is it confusing that this default behavior means you can build a box with the exact same recipes and get a different result?* pragmatic reason to be inconsistent: the risk of upgrading packages by default is so great that it's better if everyone using Chef learns that this is inconsistent, and why, and how to deal with it.Thoughts?Brian--Daniel DeLeo
Archive powered by MHonArc 2.6.16.