Sean, Your kindness is amazing. The whole design you depicted is very clear and I like so much new mysql flavour. I also know that I can use template_source parameter and actually i am already doing it :-) Our use case is not so easy to explain: we are working to take CHEF and devops in a traditional and legacy ICT company, not very agile but heavy processes driven. At the beginning of this year three different teams were set up: an automation team that works to provide what we call "core cookbooks", a team that assembles core cookbooks into environment cookbooks to deploy application stack infrastructures and a team that deploys applications using the same environment cookbooks. In this situation it is not so easy to spread necessary knowledge among all these teams, so core-team is currently providing cookbooks whose recipes need only to be included and configured via overridden attributes. In this specific case Core-team provides 'company_mysql' cookbook, that uses mysql_service resource inside a recipe inst_mysql that sets up and manage mysql in our standard way. Environment cookbook team provides 'myface' environment cookbook that includes 'company_mysql::inst_mysql' like many other environment cookbooks do. 'company_mysql::inst_mysql' is a general recipe very easy to use (you just have to include it). The problem is that while 'company_mysql::inst_mysql' can use 'template_source' parameter, no 'template_cookbook' parameter exists, so when 'myface' includes 'company_mysql::inst_mysql' it can't specify a my.cnf template different from another environment cookbook ('yourface' for example) also using the same core cookbook ('company_mysql::inst_mysql') because template resource of mysql_service is taken from the cookbook that uses it ('company_mysql::inst_mysql'). Off course a possible solution would be to drop 'company_mysql' core cookbook and having our environment cookbooks to directly use mysql_service, but our current approach is to let our company start using CHEF lowering as much as possible complexity and learning curve. My purpose wasn't to modify a primitive resource internal, I just would like there was a way to specify a 'template_cookbook' parameter also :-) Any comment, criticism and/or advice is really appreciated. Marco
|
Archive powered by MHonArc 2.6.16.