You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Richard In Public <ed...@blueyonder.co.uk> on 2004/03/03 18:13:23 UTC

SVN my linux box - sanity check

Hi All

The (inherently complex) configuration of a linux installation begs to 
be versioned.  Here is what I'm planning to do:

[After backing up all files to be versioned]

1.  Create an empty "installation" repository
2.  Checkout a working copy into / (i.e. / now contains .svn)
3.  Add /etc and, for example, /opt/tomcat/conf to repository (add, commit)
4...  Commit / after updating configuratons enabling rollbacks, diff, etc.

The two issues that come to mind are:
1. Security - obviously the repository needs to be closely guarded
2. Permissions - this is only useful if svn 'remembers' the permissions 
of each file

A quick test suggests that SVN does indeed restore permissions as 
checked in.  So no problems?

Well, I thought I'd see if anyone has tried this or forsees any problems 
with this scheme...

best regards,

Richard Hoberman

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: SVN my linux box - sanity check

Posted by Calvin Spealman <ca...@ironfroggy.com>.
On Wednesday 03 March 2004 1:13 pm, Richard In Public 
<ed...@blueyonder.co.uk> wrote:
> Hi All
>
> The (inherently complex) configuration of a linux installation begs to
> be versioned.  Here is what I'm planning to do:
>
> [After backing up all files to be versioned]
>
> 1.  Create an empty "installation" repository
> 2.  Checkout a working copy into / (i.e. / now contains .svn)
> 3.  Add /etc and, for example, /opt/tomcat/conf to repository (add, commit)
> 4...  Commit / after updating configuratons enabling rollbacks, diff, etc.
>
> The two issues that come to mind are:
> 1. Security - obviously the repository needs to be closely guarded
> 2. Permissions - this is only useful if svn 'remembers' the permissions
> of each file
>
> A quick test suggests that SVN does indeed restore permissions as
> checked in.  So no problems?
>
> Well, I thought I'd see if anyone has tried this or forsees any problems
> with this scheme...
>
> best regards,
>
> Richard Hoberman
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org

I think thats a great idea, assuming it goes well, of course. If it doesn't 
then any work needed to make it work properly would be worth the effort. I 
can see all kinds of benefits, aside from the obviousness of rolling a system 
back to a working copy.

I would even consider adding more directories to the repository, such as /home 
and maybe /boot .  You'll probably want to omit some things from the 
repository, like /tmp and such.

I administer my family computer and i'm always looking for ways to make things 
nicer for them, and I think it would be cool to have a nice interface to 
this. A little K app to let them commit their $HOME or something.

Anyway, I'm ranting a bit, but I like to get ideas out for others to comment 
on how stupid or genius I am :-D

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: SVN my linux box - sanity check

Posted by Robert Guthrie <rg...@pobox.com>.
Richard In Public wrote:
> Hi All
> The two issues that come to mind are:
> 2. Permissions - this is only useful if svn 'remembers' the permissions 
> of each file
> 
> A quick test suggests that SVN does indeed restore permissions as 
> checked in.  So no problems?

Being a newbie, I'm not sure that this isn't just coincedence.  Plus, do 
user & group memberships remain the same, even though you're checking 
out files as just one user (root, presumbably)?  You might want to do a 
find  [dirs & options] -ls > backuplist.txt and keep that under 
subversion as well.  If you ever had to restore from the svn repository, 
you'd have something from which to re-assign ownership if it didn't do 
what you expected.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: SVN my linux box - sanity check

Posted by Brian Mathis <bm...@directedge.com>.
You might be interested a tool called "cfengine".  Here's it's homepage:
    http://www.cfengine.org/
and a nice intro article at Linux Journal (though you don't need a
network config for just 1 machine):
    http://www.linuxjournal.com/article.php?sid=6848

I think when most people think about versioning config files, they are
really looking for something like cfengine - though svn will probably
work as well.

As far as permissions go in svn, it will only restore them to whatever
the current user's umask is set to.  Files like /etc/shadow that are
private will probably not be restored properly.


Richard In Public wrote:

> Hi All
>
> The (inherently complex) configuration of a linux installation begs to 
> be versioned.  Here is what I'm planning to do:
>
> [After backing up all files to be versioned]
>
> 1.  Create an empty "installation" repository
> 2.  Checkout a working copy into / (i.e. / now contains .svn)
> 3.  Add /etc and, for example, /opt/tomcat/conf to repository (add, 
> commit)
> 4...  Commit / after updating configuratons enabling rollbacks, diff, 
> etc.
>
> The two issues that come to mind are:
> 1. Security - obviously the repository needs to be closely guarded
> 2. Permissions - this is only useful if svn 'remembers' the 
> permissions of each file
>
> A quick test suggests that SVN does indeed restore permissions as 
> checked in.  So no problems?
>
> Well, I thought I'd see if anyone has tried this or forsees any 
> problems with this scheme...
>
> best regards,
>
> Richard Hoberman
>
>  


-- 
Brian Mathis
http://directedge.com/b/



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org