[chef] Re: Re: same Rakefile in multiple cookbook git repos


Chronological Thread 
  • From: Torben Knerr < >
  • To:
  • Subject: [chef] Re: Re: same Rakefile in multiple cookbook git repos
  • Date: Thu, 24 Sep 2015 22:45:03 +0200

Or put it in a generator cookbook template for when you 'chef generate cookbook'

Am 24.09.2015 8:30 nachm. schrieb "Ranjib Dey" < "> >:
capture those common rake tasks in a library, make a gem, use it in your rakefiles.

On Thu, Sep 24, 2015 at 11:05 AM, loafy junk < " target="_blank"> > wrote:
Hi,
I'm following the single cookbook per git repo pattern.  I use a Rakefile to run tasks for style, unit test, integration tests(local vm/docker or cloud).  I noticed I've got the same Rakefile in many repos now.  If I want to make a change to the Rakefile I'm going to be changing/pushing in many git repos.  I'd like to have a single 'master' Rakefile that each git repo can reference.  Anyone else solved this?

Some ideas I had after searching around the internets are:
- keep Rakefile in its own git repo

THEN

- pull into each cookbook git repo from rake repo
  - how do you manage this? 
    - I've seen git-submodules mentioned, not in a kind light 
    - tools like giternal, braid, ...
    - add a rake task to Rakefile so it can self update, kind of like this: https://github.com/cloudware-cookbooks/skeleton/blob/master/Rakefile

OR

- pull Rakefile from artifact repo(nexus, artifactory, etc). It is pushed to artifact repo whenever changes are made in rake.repo

Thanks.
-Maciej




Archive powered by MHonArc 2.6.16.

§