Getting the latest source code for Coupa Open Source isn’t as hard as you might think. Of course, if you want our previously published releases, you can get them from Sourceforge. But for those that want to see the stuff as it is checked-in, I figured I would explain from a “non-technical” perspective. If you aren’t a novice like myself and already have things like mySQL installed, then you can just check out the Trac Wiki site. These are instructions for someone on Windows. If you’d like Linux or Mac instructions, leave a comment and I’ll do those too. Before you try to download the code, here are a few things you need to do:
- Install TortoiseSVN – It’s a very easy Windows shell extension for accessing the source code. Download here
- Install MySQL – You can choose other databases, but this one is straightforward. I’d do the Community Server (open source) for currently the latest stable edition 5.0 and pick the Windows Essentials install here. I don’t have all the install steps, but follow the defaults. Recommend that you choose the defaults or set them to have username of root, hostname of localhost (127.0.0.1), port 3306, and no password.
- Create a new schema in mySQL – After install of MySQL, use the MySQL Administrator to log into MySQL and create a schema for Coupa. To do this, once logged in, you’ll see a bunch of options on your left hand side of MySQL administrator, click catalogs. A “Schemata” list will drop-down. Right click in the list of schemas (which should have a couple like mysql and test) and pick “Create new schema”. Enter “coupa_development” for the name of the new schema.
- Install Ruby. You can get our programming language by going here. I’d pick the Windows installer which will take you to the download page on RubyForge. I did the 1.8.4-19 Final release (the .exe one). Install that program. You’ll be asked what additional components to install. Make sure the Enable RubyGems is installed. The others are optional. After installing, I had to set the PATH to include the key newly created Ruby directories…but others said that this was taken care of automatically. If you need to set them, use the Environment Variables (in Systems Properties) to include your location of install. For me, that was C:\ruby;C:\ruby\bin
- Install additional engines for Ruby. Open up a cmd.exe window. Type in the following:
- “gem install ferret”. BTW, you’ll need to pick the latest ferret that is supported and appropriate for your environment, which currently is 0.10.9 (mswin32)
- “gem install vpim”
- “gem install rails –include-dependencies”
You’re about 75% of the way there! Now, let’s fetch the code. First, create a folder on your local drive…in this case, we’ll create C:\CoupaOS. Now, navigate to that folder and right click on it. You should see “TortoiseSVN” in the list. Pick TortoiseSVN which will open a subfolder (or sub-option). On the top of that, you should be able to pick “Checkout…”. Type in “http://svn.coupa.com/coupa/trunk” as the URL of the repository, which is where our source code is. Select “OK” and it should start fetching all the source code. After a couple minutes, you’ll have the whole application on your machine.
The next step is to load the schema in MySQL on your machine. Here are the steps:
- Open a cmd.exe window and navigate to the CoupaOS directory. Type “copy config\databases\database.mysql config\database.yml”. This tells the system that MySQL is the database of choice.
- Type “rake db:schema:load”
- Type “rake db:seed:engines:load”
Now, you are ready to run. From now on, everytime you want to startup Coupa eProcurement on your machine, all you need to do is open a cmd.exe window, navigate to C:\CoupaOS and type “ruby script/server”. That turns everything on. Now go to your web browser of choice and type in “http://localhost:3000/”. You’ll be asked to log in. “williams” is the username of the system administrator with “welcome” as the password. Three things of note:
- Let’s say, a week later, you want to grab all the new checkins. You use Windows and navigate to the CoupaOS folder and right click. You should see “SVN Update…” as an option. Pick that and the system should download all deltas. Occasionally, we may have some schema changes which require some additional steps. You are taking the latest and that has risks
- If you want to use the bulk loader, which allows you to load in things like users, catalog items, accounts, suppliers, etc., you need to start the bulkloader. Before you type in “ruby script/server”, you’ll need to type in “rake backgroundrb:start” to get the loaders up and going.
- We rely on an smtp server to send notifications (e.g., approval notifications) out of Coupa to your email system. If you don’t set it up, notifications will still end up in the notification inbox of the Coupa user (they just won’t get sent to your email inbox).
I’ll also be posting this in the Coupa Forums. We’d love to see you posting questions/comments/thoughts/whatever in our Forums!

