Code Ocean is an educational tool for web-based coding exercises
Ruby HTML JavaScript CSS Shell Java Other
Latest commit 9b8027e Feb 14, 2017 @rteusner rteusner replaced exit-command for containers from 'exit' to '#exit', otherwis…
…e it will always really exit the container (which is then in state: exited) if we execute it in bash.
Permalink
Failed to load latest commit information.
app replaced exit-command for containers from 'exit' to '#exit', otherwis… Feb 14, 2017
bin updated rails from 4.1.13 to 4.2.5. This is required for rails to mak… Dec 30, 2016
config removed relative_url_root for staging environment. Feb 6, 2017
db fixing tests p1 Jan 12, 2017
debian_installer updated rails from 4.1.13 to 4.2.5. This is required for rails to mak… Dec 30, 2016
lib Fixed rejection of untagged images Jan 18, 2017
public Bar chart Mar 28, 2016
spec fixed broken test Jan 19, 2017
vendor/assets Commit just for you, Ralf :) Mar 27, 2015
webpython Update webpython.py Oct 16, 2015
.gitignore Merge branch 'master' into editor-frontend-refactor Sep 2, 2016
.rspec use pry-byebug gem instead for pry (recommended for ruby 2.x) May 30, 2016
.rspec.travis added RSpec configuration file Feb 23, 2015
.rubocop.yml extended RuboCop configuration Feb 24, 2015
.travis.yml tell travis to use postgres 9.5 Dec 30, 2016
Capfile transferred Code Ocean from original repository to GitHub Jan 22, 2015
Gemfile updated rails from 4.1.13 to 4.2.5. This is required for rails to mak… Dec 30, 2016
Gemfile.lock Updated nokogiri Jan 13, 2017
LICENSE minor license fixes Feb 16, 2015
LOCAL_SETUP.md Update LOCAL_SETUP.md Nov 15, 2016
README.md Update README.md May 12, 2016
Rakefile transferred Code Ocean from original repository to GitHub Jan 22, 2015
Vagrantfile Provide deployment into vagrant box. Closes #21. Aug 27, 2015
codeocean-dockerconfig.md make travis green again Oct 8, 2016
config.ru make travis green again Oct 8, 2016
provision.sh upgraded provision Jan 30, 2017

README.md

Code Ocean

Build Status Code Climate Test Coverage Dependency Status

Development Setup

Mandatory Steps

  • install the Docker client
  • run bundle install
  • create config/action_mailer.yml
  • create config/database.yml
  • create config/secrets.yml
  • customize config/docker.yml.erb

Exemplary configuration files are available in the config directory.

In order to execute code submissions using Docker, source code files are written to the file system and are provided to a dedicated Docker container. These files are temporarily written to Rails.root/tmp/files/. Please make sure that workspace_root in config/docker.yml.erb corresponds to that directory or to a linked directory if using a remote Docker server.

Optional Steps

  • create config/sendmail.yml
  • create config/smtp.yml
  • use boot2docker or vagrant if there is no native support for docker on your OS
  • create seed data by executing rake db:seed
  • if you already created a configuration for your local installation and want to use vagrant, too, be sure to log into the vagrant instance via ssh and add your database user manually to the database. Afterwards, create, migrate and seed.

Production Setup

  • create production configuration files (database.production.yml, …)
  • customize config/deploy/production.rb if you want to deploy using Capistrano

Useful service maintenance commands

  • delete all containers (include running ones) docker rm -f $(docker ps -aq)
  • if the application is run as a service restart it by using service codeocean restart
  • /etc/init.d/postgresql restart
  • if deployed via capistrano you will find the logs at /var/www/app/shared/log/ -> production.log

Roadmap

1.1

[x] WebSocket Suppport [x] Interactive Exercises [ ] Allow Disabling of File Creation [ ] Set Container Recyling per Environment