I just want to emphasise how much I appreciated this post. I’ve tried getting Vagrant up on Windows before (“Unixism” is a great word for it) and the process failed for me in myriad ways.
Aside: since then, I’ve discovered gow (Gnu On Windows), which is a really lightweight and portable library of binaries like ssh, curl, and the basics like ls - it’s a lot more convenient than Cygwin. Cygwin can be agonising when you have to deal with Ruby gems. It’s also a smidgeon more convenient than Git Bash in quite a lot of places.
Anyway, thanks so much for making this process a bit clearer. I can’t wait to have a look around Discourse - this is my first post, and I’m astounded by how perfectly considered the UI design is.
Clone the project: git clone git@github.com:discourse/discourse.git
Enter the project directory: cd discourse
Then continue on with the rest of the instructions … (I’m getting an error with the NFS client thing, but that should work, I’m investigating that and will update this when I find the cause.)
To add to your reply to @ndc, they just recently released a way to add a new provider, so it is possible to get it going on hyper-v if someone was willing to do the leg-work for vagarent. http://docs.vagrantup.com/v2/plugins/providers.html
I’m not familiar enough with vagrant to know if its something i’m going to be looking into or not, but I am interested in automating deployments to various VMs. Thanks for pointing it out.
With windows 8 coming with hyper-v as an install option out of box, it sounds like a no-brainer. Also, the free version of hyper-v 2012 is excellent. I just set up a cluster of 3 machines in my basement and have been using no shared state live-migration to offload working servers that I set up on my windows-8 box onto the cluster. its fantastic.
Okay, I want to help with Discourse, but I’ve never did anything in ruby at all and I’m a chicken, so I will go to this cool ruby workshop I found in my city where we all hang out to learn ruby together. Once I’m done and feel ready, I’ll start doing things for the project and I believe this to be the best place to let you all know. Also, what about native linux users? You feel we are strong and independent and will figure things out on our own? Or have we been forgotten?
@Hanzo That would describe me 100%. That is why I am very interested in looking at Discourse and the article is very helpful in setting up a dev environment.
I finally got discourse running locally. I am running OSX Mtn Lion. I kept running into vagrant errors and db errors. So I just uninstalled everything (via the included uninstall tools for Vagrant and VirtualBox). Then I installed the exact versions of each that are mentioned in the instructions from the blog post. I didn’t get the newer versions of either Vagrant or VirtualBox.
VirtualBox: “As of this writing, 4.2.10 is the latest and works for us.”
Vagrant: “you’ll need Vagrant 1.1.2 or higher” (don’t go higher)
Using the shared folder /vagrant will provide really low performance.
If you want decent performance, you will need to do the following:
# create an alias to synchronize the code from the shared folder to a local folder
alias sin="rsync -a --delete /vagrant ~"
# actually synchronize (can take a minute for the first run)
sin
# switch to the local folder
cd ~/vagrant
# standard procedure to update, migrate and launch the application
bundle install
bundle exec rake db:migrate
bundle exec rails s
This was pretty painless on the mac, I see why you would want to use vagrant on windows and I guess it removes any env issues on the mac as well? I ask because I the only time I set up a VM is to test IE on my MBP
Anyways set up was cooll, thanks for the fun