Le lundi 05 août 2013, à 13:03 +0100, Adam Spiers a écrit :
> Vincent Untz ([email protected]) wrote:
> > Le lundi 05 août 2013, à 12:39 +0100, Adam Spiers a écrit :
> > > Vincent Untz ([email protected]) wrote:
> > > > A few weeks ago, I started the work on allowing schema changes in
> > > > pebbles, without breaking existing proposals. In short, there's a
> > > > migration rake task that will update the proposal (and its matching
> > > > role, if committed) to the updated schema.
> > > 
> > > [snipped]
> > > 
> > > Looks good to me except for the point I already made:
> > > 
> > > >   - there are migration scripts in
> > > >     /opt/dell/chef/data_bags/crowbar/migrate/$barclamp/. The scripts
> > > >     must be named $rev_$somedescription.rb; the filename can have
> > > >     0 (001_foobar.rb will work as well as 1_foobar.rb). There can be
> > > >     multiple scripts per revision; they will be executed by alphabetical
> > > >     order (or reverse alphabetical order in case of downgrades).
> > > 
> > > https://github.com/crowbar/barclamp-crowbar/pull/613#issuecomment-21722923
> > 
> > Ah, I had forgotten about that one :-)
> > 
> > As the migration scripts will be provided by the barclamp, and most
> > barclamps won't need more than one migration script per revision, such a
> > requirement on the naming of the migration scripts is, imho, not needed.
> > People can do it, but forcing this is a bit too much to my taste. Don't
> > know how others feel, though?
> 
> I agree it's not pretty.  I was just worried about engineering
> ourselves into a corner with no obvious way out.  
> 
> If we were ever in a position where we originally thought only one
> script xxx_foo.rb would be required for a given (barclamp, revision)
> combination, and then we realised we needed more than one, and the
> order mattered, then I guess we could rename xxx_foo.rb to
> xxx_01_foo.rb before introducing xxx_02_bar.rb?

Sure, the names can be changed and things will still work perfectly
fine.

Vincent

-- 
Les gens heureux ne sont pas pressés.

_______________________________________________
Crowbar mailing list
[email protected]
https://lists.us.dell.com/mailman/listinfo/crowbar
For more information: http://crowbar.github.com/

Reply via email to