I was hosting the subversion server for Energy Hook on Unfuddle, but that got pricey after I hit the free tier storage limit. So, at the suggestion of @Kostas_Zarifis, I switched to hosting on EC2, which took most of a day to figure out but has only cost around a dollar a month.
But I'm an idiot and forgot my password and deleted the key pair file which had been lingering in my downloads directory and purged long ago. Whoops.
So I had to do this again, and was taking notes on the process as I went, but decided to reboot my computer midway because I was having internet issues, and, well...lost the notes. So, here's my best attempt to reconstruct them, but there could be some gaps. If you try this and have trouble, let me know where you get hung up in the comments.
- After I have my EC2 account set up, Launch Instance
- I choose Windows 2008 R2 Server.
- I go to Add Storage because I know that 30 gigs is going to get used up quick (almost 20 of it starts out used by the OS, etcetera). This is costing me around $10 a month but is still cheaper than unfuddle. If you want the free SVN, leave it at the free level!
- I confirm and Launch.
- I generate the Key Pair.
- I right click on the instance once it's running and Get Windows Password.
- THIS TIME, I'm saving my Key Pair and Password someplace safe. :P
- I connect with Remote Desktop and find that I can't seem to download SVN or anything.
- So I go to Server Manager->Server Summary->Security Information->Configure IE ESC and turn that shit off for Administrators, whatever it is.
- Okay, I can download stuff now. This time I'm going to be better than last time, I'm going to use VisualSVN Server, which has more security!
- I manage to set up a test repo, (using https: and port 443) and I can connect to it from the Server, but not from anywhere else. Do I have the port wrong? The address? Firewall problems? Who knows!
- Eventually I figure out to go to the EC2 Management Console->Security Groups->the group for my new instance, and add rules not only for TCP port 443 but also ICMP, so I can just Ping the darn thing and make sure I see it at all. (After I add the rule I have to remember to Apply Rule Changes.)
- Now things seem to work from the client side. I can
svn ls https://my-public-ip-here:443/svn/happionlabs
and see my test repo. (There was a moment of hilarity, because in trying to figure out what was wrong I turned off the https: security on the server side, which changed the port to 80 without me noticing, so I couldn't figure out why, now that I'd figured out how to open the freaking ports, things still didn't work. Haha. Ha.)
So there it is. A bit of extra work but a thing.
This is a great post. I'm always curious about better ways to store my code off-site. See my low-tech shenanigans here: http://gamedeveloperjourney.blogspot.com/2013/10/whats-your-backup-strategy.html
It looks like you may have a good setup here, especially for collaborating with others. Is it seriously only $1 a month? Might be a good investment even for my small project...
Posted by: Jeromie Walters | October 30, 2013 at 01:10 PM
I've been considering setting up a public SVN repo, but hadn't seen any hosting options that really interested me until now.
I use VisualSVN Server on the local network already, so I'm please to see that it's an option on EC2. It's just so easy to use, the thought of setting up an SVN server instance on a Linux box sounds like an unimaginable nightmare by comparison.
Definitely going to look into this. Thanks for the post :)
Posted by: Takuan Daikon | October 30, 2013 at 03:35 PM
I did something similar for git on EC2, including automating the startup and shutdown of the EC2 instance as part of the push/pull.
http://flagrantsystemerror.com/#git-sync-ec2
In addition it also is set up to deploy from the rermote git repository as well using hooks.
Posted by: Jay K. | November 02, 2013 at 11:02 AM