You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Eric Rousse <er...@telmatik.com> on 2006/07/26 21:16:21 UTC

IIS and SVN

Hi Guys,

I've did a couple of search about IIS and SVN and I haven't found a 
clear solution to my problem.

Currently I've did a setup of SVN on a Windows 2000 server, it's working 
perfectly fine. That server is currently our dev server running IIS.
What I did, is that I've installed svnserve on it, and every time 
someone does an modification on a file then a commit, via TortoiseSVN 
(on their PC). It calls a post-commit hook on the server.

post-commit.bat
C:\Progra~1\Subver~1\bin\svn update D:\websites\bluffm~1.com


It works okay, but of course, I'm getting all the .svn folders in my 
websites, no big deal since its a dev site, but still I'm looking for 
other solution, if there's any...

I haven't seen any clear solution and windows based solution about 
that... I've heard a couple of solution with perl possibly, and by using 
svn export (but in this case we have to find a way to delete removed 
files, right ?)


The other problem, is that since the dev ppl, have access to the dev 
server via SVN, I was wondering, how we could automate the update of our 
prod server easily ? Either via the dev pc by using another repository 
to send the stuff to the prod server or with simply a script on the 
server it self, that could update the prod one. I was thinking of maybe 
a asp page that could call an svn update or export from the prod server. 
That way the dev ppl could do a deploy themself...

Thanks for any input!

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

Re: IIS and SVN

Posted by Steve Williams <st...@kromestudios.com>.
Eric Lemes wrote:
> There's a environment variable to make svn create his folders as 
> "_svn". I think the right variable is in the subversion book.
>  
> Anyway, if you install TortoiseSVN, it has a ".NET Hack" install 
> option that sets everything for you.
>  
> Eric Lemes
>
>  
> On 7/26/06, *Eric Rousse* <eric.rousse@telmatik.com 
> <ma...@telmatik.com>> wrote:
>
>     Hi Guys,
>
>     It works okay, but of course, I'm getting all the .svn folders in my
>     websites, no big deal since its a dev site, but still I'm looking for
>     other solution, if there's any...
>
>     I haven't seen any clear solution and windows based solution about
>     that... I've heard a couple of solution with perl possibly, and by
>     using
>     svn export (but in this case we have to find a way to delete removed
>     files, right ?)
>

The .NET hack is for a completely different issue.  Ignore it.  It does 
not apply to your situation.

-- 
Sly



This message and its attachments may contain legally privileged or confidential information. This message is intended for the use of the individual or entity to which it is addressed. If you are not the addressee indicated in this message, or the employee or agent responsible for delivering the message to the intended recipient, you may not copy or deliver this message or its attachments to anyone. Rather, you should permanently delete this message and its attachments and kindly notify the sender by reply e-mail. Any content of this message and its attachments, which does not relate to the official business of the sending company must be taken not to have been sent or endorsed by the sending company or any of its related entities. No warranty is made that the e-mail or attachment(s) are free from computer virus or other defect.

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

Re: IIS and SVN

Posted by Toby Johnson <to...@etjohnson.us>.
Foy, Sean wrote:
>> And Sean, just wondering how would you manage your deploy 
>> with svn export ? If I do a svn export over a current 
>>     
>
> I was just pointing out that in principle you don't need
> the .svn admin directories on your web server, because
> they just have SVN metadata and base versions of your
> files.
>   

Having those .svn directories on the live server also offers you the 
great benefit of using Subversion's highly-efficient update mechanism to 
push changes to your server. Only lines which have changed need to be 
pushed and it happens very quickly, because those working copies keep 
track of when the last update happened, and what the files looked like, 
so only the changes themselves need to be updated. Best deployment 
strategy I've ever used.

There are also those times when I'm away from a dev box and I need to 
make an emergency change on the production server. In that case I just 
make the change and commit it from the production server. Of course that 
should be avoided whenever possible but when it is necessary, it's nice 
to know that Subversion will let me easily see what changes I made and 
ensure that I don't forget to commit them back to the repo, to prevent 
them from being lost next time a dev change is made.

toby

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

RE: Re: IIS and SVN

Posted by "Foy, Sean" <Se...@TycoHealthcare.com>.
> And Sean, just wondering how would you manage your deploy 
> with svn export ? If I do a svn export over a current 

I was just pointing out that in principle you don't need
the .svn admin directories on your web server, because
they just have SVN metadata and base versions of your
files.

As Ryan points out, you might choose to use a working
copy anyway, which would allow you to use something like
the svn-clean script that comes with Subversion (in contrib)
to remove files that are no longer in HEAD.

Or, you could use "svn ls" and delete files that aren't
listed. Or, you could delete everything on the target
and copy everything.

Personally, I use CruiseControl.NET and NAnt. CC.NET
watches for changes in SVN. It has its own working copy.
Whenever there is a change, CC.NET tells NAnt to compile
our ASP.NET project, test it, and deploy it. NAnt decides
what files need to be updated on the web server, what should
be removed, etc. CC.NET gathers up NAnt's results, summarizes
them, and publishes them to its own web site/RSS feed and
emails certain people about test failures or successful
deployments.

Sean

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


Re: IIS and SVN

Posted by Eric Rousse <er...@telmatik.com>.
Hi Guys,

Thanks for all the replies, I think i'll take a look at CruiseControl it 
seems nice.
Also about the .svn folder, its stupid but I didn't thought about 
disallowing this directly from IIS. :P

And Sean, just wondering how would you manage your deploy with svn export ?
If I do a svn export over a current existing copy, if there was old 
files in the head copy, basically it won't delete
those files in my local copy. So theorically, I would have to delete 
everything then do export ? Or do you have another way ?

Thanks guys!

Ryan Schmidt a écrit :
> On Jul 27, 2006, at 04:25, Foy, Sean wrote:
>
>> On Jul 26, 2006, at 23:16, Eric Rousse wrote:
>>
>>> Currently I've did a setup of SVN on a Windows 2000 server, it's 
>>> working perfectly fine. That server is currently our dev server 
>>> running IIS.
>>> What I did, is that I've installed svnserve on it, and every time 
>>> someone does an modification on a file then a commit, via 
>>> TortoiseSVN (on their PC). It calls a post-commit hook on the server.
>>>
>>> post-commit.bat
>>> C:\Progra~1\Subver~1\bin\svn update D:\websites\bluffm~1.com
>>>
>>>
>>> It works okay, but of course, I'm getting all the .svn folders in my 
>>> websites, no big deal since its a dev site, but still I'm looking 
>>> for other solution, if there's any...
>>>
>>> I haven't seen any clear solution and windows based solution about 
>>> that... I've heard a couple of solution with perl possibly, and by 
>>> using svn export (but in this case we have to find a way to delete 
>>> removed files, right ?)
>>>
>>>
>>> The other problem, is that since the dev ppl, have access to the dev 
>>> server via SVN, I was wondering, how we could automate the update of 
>>> our prod server easily ? Either via the dev pc by using another 
>>> repository to send the stuff to the prod server or with simply a 
>>> script on the server it self, that could update the prod one. I was 
>>> thinking of maybe a asp page that could call an svn update or export 
>>> from the prod server. That way the dev ppl could do a deploy 
>>> themself...
>>
>> Those .svn directories indicate that you have SVN working copies. You
>> don't want working copies if you don't plan to contribute changes back
>> to the repository from that machine. You can use something like svn's
>> export command to just download a snapshot of the repository contents to
>> a directory so that you can serve up those contents using IIS.
>
> Sean, using a working copy is a very convenient way to update a 
> production web site, and it's even recommended in the FAQ:
>
> http://subversion.tigris.org/faq.html#website-auto-update
>
> That entry also addresses Eric's concern about the .svn directories -- 
> you simply configure the web server to deny access to those. The 
> example provided is for Apache; for IIS you'll have to consult their 
> documentation.
>
> For deploying to a different server, there are a number of options. 
> One good solution is to have the post-commit hook on the repository 
> machine connect to the production server via ssh and execute the 
> update command that way, e.g.:
>
> ssh production.example.com svn update /path/to/working/copy
>
> You can configure SSH so that no username or password is necessary to 
> log in, by using public/private keypairs on both machines.
>
>
>
>

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

Re: IIS and SVN

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Jul 27, 2006, at 04:25, Foy, Sean wrote:

> On Jul 26, 2006, at 23:16, Eric Rousse wrote:
>
>> Currently I've did a setup of SVN on a Windows 2000 server, it's  
>> working perfectly fine. That server is currently our dev server  
>> running IIS.
>> What I did, is that I've installed svnserve on it, and every time  
>> someone does an modification on a file then a commit, via  
>> TortoiseSVN (on their PC). It calls a post-commit hook on the server.
>>
>> post-commit.bat
>> C:\Progra~1\Subver~1\bin\svn update D:\websites\bluffm~1.com
>>
>>
>> It works okay, but of course, I'm getting all the .svn folders in  
>> my websites, no big deal since its a dev site, but still I'm  
>> looking for other solution, if there's any...
>>
>> I haven't seen any clear solution and windows based solution about  
>> that... I've heard a couple of solution with perl possibly, and by  
>> using svn export (but in this case we have to find a way to delete  
>> removed files, right ?)
>>
>>
>> The other problem, is that since the dev ppl, have access to the  
>> dev server via SVN, I was wondering, how we could automate the  
>> update of our prod server easily ? Either via the dev pc by using  
>> another repository to send the stuff to the prod server or with  
>> simply a script on the server it self, that could update the prod  
>> one. I was thinking of maybe a asp page that could call an svn  
>> update or export from the prod server. That way the dev ppl could  
>> do a deploy themself...
>
> Those .svn directories indicate that you have SVN working copies. You
> don't want working copies if you don't plan to contribute changes back
> to the repository from that machine. You can use something like svn's
> export command to just download a snapshot of the repository  
> contents to
> a directory so that you can serve up those contents using IIS.

Sean, using a working copy is a very convenient way to update a  
production web site, and it's even recommended in the FAQ:

http://subversion.tigris.org/faq.html#website-auto-update

That entry also addresses Eric's concern about the .svn directories  
-- you simply configure the web server to deny access to those. The  
example provided is for Apache; for IIS you'll have to consult their  
documentation.

For deploying to a different server, there are a number of options.  
One good solution is to have the post-commit hook on the repository  
machine connect to the production server via ssh and execute the  
update command that way, e.g.:

ssh production.example.com svn update /path/to/working/copy

You can configure SSH so that no username or password is necessary to  
log in, by using public/private keypairs on both machines.


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

RE: Re: IIS and SVN

Posted by "Foy, Sean" <Se...@TycoHealthcare.com>.
Those .svn directories indicate that you have SVN working copies. You
don't want working copies if you don't plan to contribute changes back
to the repository from that machine. You can use something like svn's
export command to just download a snapshot of the repository contents to
a directory so that you can serve up those contents using IIS.

As for allowing developers to deploy code without an admin's help: I
suggest you look into continuous integration software such as
http://confluence.public.thoughtworks.org/display/CCNET/Welcome+to+Cruis
eControl.NET. This software can monitor your SVN repository for changes
and conditionally build/deploy your software and notify whoever you like
whenever something interesting happens.

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


Re: IIS and SVN

Posted by Eric Lemes <er...@gmail.com>.
There's a environment variable to make svn create his folders as "_svn". I
think the right variable is in the subversion book.

Anyway, if you install TortoiseSVN, it has a ".NET Hack" install option that
sets everything for you.

Eric Lemes


On 7/26/06, Eric Rousse <er...@telmatik.com> wrote:
>
> Hi Guys,
>
> I've did a couple of search about IIS and SVN and I haven't found a
> clear solution to my problem.
>
> Currently I've did a setup of SVN on a Windows 2000 server, it's working
> perfectly fine. That server is currently our dev server running IIS.
> What I did, is that I've installed svnserve on it, and every time
> someone does an modification on a file then a commit, via TortoiseSVN
> (on their PC). It calls a post-commit hook on the server.
>
> post-commit.bat
> C:\Progra~1\Subver~1\bin\svn update D:\websites\bluffm~1.com
>
>
> It works okay, but of course, I'm getting all the .svn folders in my
> websites, no big deal since its a dev site, but still I'm looking for
> other solution, if there's any...
>
> I haven't seen any clear solution and windows based solution about
> that... I've heard a couple of solution with perl possibly, and by using
> svn export (but in this case we have to find a way to delete removed
> files, right ?)
>
>
> The other problem, is that since the dev ppl, have access to the dev
> server via SVN, I was wondering, how we could automate the update of our
> prod server easily ? Either via the dev pc by using another repository
> to send the stuff to the prod server or with simply a script on the
> server it self, that could update the prod one. I was thinking of maybe
> a asp page that could call an svn update or export from the prod server.
> That way the dev ppl could do a deploy themself...
>
> Thanks for any input!
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org
>
>

Re: IIS and SVN

Posted by Markus KARG <ma...@quipsy.de>.
Eric,

I not quite clear what you want to do, but it maybe CruiseControl would 
be good for you. It scans SVN and if there was a change, it does 
whatever you like (building, publishing results to web sites, sending 
emails, etc.).

Markus

Eric Rousse schrieb:

> Hi Guys,
>
> I've did a couple of search about IIS and SVN and I haven't found a 
> clear solution to my problem.
>
> Currently I've did a setup of SVN on a Windows 2000 server, it's 
> working perfectly fine. That server is currently our dev server 
> running IIS.
> What I did, is that I've installed svnserve on it, and every time 
> someone does an modification on a file then a commit, via TortoiseSVN 
> (on their PC). It calls a post-commit hook on the server.
>
> post-commit.bat
> C:\Progra~1\Subver~1\bin\svn update D:\websites\bluffm~1.com
>
>
> It works okay, but of course, I'm getting all the .svn folders in my 
> websites, no big deal since its a dev site, but still I'm looking for 
> other solution, if there's any...
>
> I haven't seen any clear solution and windows based solution about 
> that... I've heard a couple of solution with perl possibly, and by 
> using svn export (but in this case we have to find a way to delete 
> removed files, right ?)
>
>
> The other problem, is that since the dev ppl, have access to the dev 
> server via SVN, I was wondering, how we could automate the update of 
> our prod server easily ? Either via the dev pc by using another 
> repository to send the stuff to the prod server or with simply a 
> script on the server it self, that could update the prod one. I was 
> thinking of maybe a asp page that could call an svn update or export 
> from the prod server. That way the dev ppl could do a deploy themself...
>
> Thanks for any input!
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org
>