Re: [Puppet Users] How do you implement "revert changes'

2011-04-24 Thread James Turnbull
Mohamed Lrhazi wrote:
> For each change to production systems, one has to submit a script
> detailing what changes will be made and how to revert them back.. I
> was wondering if any of you, who implemented something similar, would
> care to share how they did it.

There is no such thing as rollback. :)

I wrote roll in and roll out manifests and tested both.  The roll in
manifest made the required packages.  The roll out manifest reversed
those changes.

> 
> Simply reverting puppet's own config to a previous repository version
> would not be enough in most cases, as it would not necessarily involve
> restoring overwritten files on the clients, if those files were not
> originally generated from puppet itself.

Files can be backed up remote file buckets.
> 
> I guess Puppet's buckets would be involved in the answer, but my
> understanding is that they are not documented yet, correct? is such a
> feature planned for upcoming releases?

It is documented.

http://docs.puppetlabs.com/references/2.6.7/type.html#filebucket

The feature already exists.

Regards

James

-- 
James Turnbull
Puppet Labs
1-503-734-8571

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.



Re: [Puppet Users] How do you implement "revert changes'

2011-04-20 Thread Felix Frank
On 04/19/2011 08:55 PM, Mohamed Lrhazi wrote:
> Thanks Felix But how is Filebucket currently used? Is there a
> "puppet agent --restore" functionality that I missed?

No, as a matter of fact, you missed the whole "filebucket" binary ;-)

What I do interactively a lot is

filebucket -l get 
and occasionally
filebucket -l restore /some/file 

I get the md5sums from my agent log. The -l has filebucket use the local
clientbucket (which requires a puppet.conf entry to use the correct
location).

Cheers,
Felix

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.



Re: [Puppet Users] How do you implement "revert changes'

2011-04-19 Thread Mohamed Lrhazi
Thanks Felix But how is Filebucket currently used? Is there a
"puppet agent --restore" functionality that I missed?


On Tue, Apr 19, 2011 at 3:20 AM, Felix Frank
 wrote:
> On 04/18/2011 11:22 PM, Mohamed Lrhazi wrote:
>> I forgot to think about a little detail, while introducing Puppet to
>> our environment :)
>>
>> For each change to production systems, one has to submit a script
>> detailing what changes will be made and how to revert them back.. I
>> was wondering if any of you, who implemented something similar, would
>> care to share how they did it.
>>
>> Simply reverting puppet's own config to a previous repository version
>> would not be enough in most cases, as it would not necessarily involve
>> restoring overwritten files on the clients, if those files were not
>> originally generated from puppet itself.
>>
>> I guess Puppet's buckets would be involved in the answer, but my
>> understanding is that they are not documented yet, correct? is such a
>> feature planned for upcoming releases?
>>
>> am currently thinking that our only option would be to write and run
>> scripts to backup the specific files any change would affect, prior to
>> running "puppet agent --no-noop", so the revert step would be to run
>> another script to restore the backups, restart services...
>
> Filebucket does work for this purpose already. There should be a man
> page (I know there is one in the Debian packages).
>
> Doing this in a scripted fashion may be tricky, though. It will probably
> involve parsing agent logs.
>
> HTH,
> Felix
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Puppet Users" group.
> To post to this group, send email to puppet-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> puppet-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/puppet-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.



Re: [Puppet Users] How do you implement "revert changes'

2011-04-19 Thread Felix Frank
On 04/18/2011 11:22 PM, Mohamed Lrhazi wrote:
> I forgot to think about a little detail, while introducing Puppet to
> our environment :)
> 
> For each change to production systems, one has to submit a script
> detailing what changes will be made and how to revert them back.. I
> was wondering if any of you, who implemented something similar, would
> care to share how they did it.
> 
> Simply reverting puppet's own config to a previous repository version
> would not be enough in most cases, as it would not necessarily involve
> restoring overwritten files on the clients, if those files were not
> originally generated from puppet itself.
> 
> I guess Puppet's buckets would be involved in the answer, but my
> understanding is that they are not documented yet, correct? is such a
> feature planned for upcoming releases?
> 
> am currently thinking that our only option would be to write and run
> scripts to backup the specific files any change would affect, prior to
> running "puppet agent --no-noop", so the revert step would be to run
> another script to restore the backups, restart services...

Filebucket does work for this purpose already. There should be a man
page (I know there is one in the Debian packages).

Doing this in a scripted fashion may be tricky, though. It will probably
involve parsing agent logs.

HTH,
Felix

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.



[Puppet Users] How do you implement "revert changes'

2011-04-18 Thread Mohamed Lrhazi
I forgot to think about a little detail, while introducing Puppet to
our environment :)

For each change to production systems, one has to submit a script
detailing what changes will be made and how to revert them back.. I
was wondering if any of you, who implemented something similar, would
care to share how they did it.

Simply reverting puppet's own config to a previous repository version
would not be enough in most cases, as it would not necessarily involve
restoring overwritten files on the clients, if those files were not
originally generated from puppet itself.

I guess Puppet's buckets would be involved in the answer, but my
understanding is that they are not documented yet, correct? is such a
feature planned for upcoming releases?

am currently thinking that our only option would be to write and run
scripts to backup the specific files any change would affect, prior to
running "puppet agent --no-noop", so the revert step would be to run
another script to restore the backups, restart services...

Thanks a lot,
Mohamed.

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.