Skip to content

Codalab AMI

Isabelle Guyon edited this page Oct 15, 2017 · 40 revisions

This page explains how to run an Ubuntu virtual machine on Amazon Web Services (AWS) already fully pre-configured with Codalab on it. We created for you a virtual machine image (AMI), which can be publicly accessed. Once launched, your virtual machine runs a web server through which you can access your own instance of Codalab. We explain how you can configure it to open the necessary ports for HTTP and HTTPS (i.e. to use SSL for more secure access).

1. First get familiar with AWS (if you are not familiar):

Tutorial: starting and connecting to a machine on AWS

2. Run the following AMI: codalab-instance-v1

3. Configure your machine for web access


Opening ports 80 and 443 to allow access using browser

Select your machine from your "Instances" menu in the EC2 dashboard, and click the security group 'launch-wizard-XX':

Right-click on 'launch-wizard-XX', and select 'edit inbound rules':

Click 'Add rule' and select HTTP. Then also add similarly an HTTPS rule. Save.

Editing .env file

Connect to the server, then:

cd src/codalab-competitions
git stash
git pull

You should have now the newest version of Codalbab.

ls -la

You should see a .env file, which contains the Codalab configuration. You will need to edit that file with your favorite editor (vim comes with Ubuntu. If you need emacs, use sudo apt-get install emacs).

Select your machine from your "Instances" menu in the EC2 dashboard and copy the DNS address 'Public DNS (IPv4)'. Edit the .env file: go to the CODALAB_SITE_DOMAIN field and put your DNS, e.g.:

CODALAB_SITE_DOMAIN=ec2-54-153-46-119.us-west-1.compute.amazonaws.com

Save the file and exit. Then run:

docker-compose up -d

Every time you edit .env file you must restart the services, i.e. run docker-compose down then docker-compose up -d.

You should be now able to access the codalab website at your DNS, e.g.: http://ec2-54-193-41-242.us-west-1.compute.amazonaws.com.

WARNING: Running a server via HTTP is unsafe. To run HTTPS, you need to enable SSL.

Enabling SSL

  1. Get a certificate (for free certificates, type get free ssl certificate in Google).
  2. To enable SSL, follow these instructions.

Clone this wiki locally