Coursemanager for kisallioppiminen.fi
Purpose
- Teachers can follows their students progress on assignments at kisallioppiminen.fi
- Teachers can create new courses and course keys for students
- Teachers can create target schedules to motivate students
Links to our application
- Development version of coursemanager running at heroku
- Development version of kisallioppiminen.fi running at https://ohtukisalli.github.io/
- Production version of coursemanager running at https://kurssihallinta.kisallioppiminen.fi/
- Production version of kisallioppiminen.fi running at https://beta-kisallioppiminen.github.io/
- See also separate Project info repository
Developer info
Deploying
- Push to master branch of this repository
- Travis will deploy code to heroku if all tests pass
- (do not push directly to heroku)
Database installation and configuration
- PostgreSQL (At least version 9.3) necessary
- Database settings can be found in /config/database.yml
- Install PostgreSQL
sudo apt-get update
sudo apt-get install postgresql postgresql-contrib libpq-dev
- Create Database User kisalli
sudo -u postgres createuser -s kisalli
sudo -u postgres psql
\password kisalli
Enter new password: kisalli
Enter it again: kisalli
\q
- Setup kisallioppiminen.server database
rake db:create
rake db:setup
Migrations and custom seed files:
-
Custom seed files (filename.rb) can be added to db/seeds/ and loaded with command
rake db:seed:filename
(without .rb) -
rake db:migrate
-
rake db:seed:destroy_all
- db/seeds/destroy_all.rb (destroys database content) -
rake db:seed:dev
- db/seeds/dev.rb (content for dev environment) -
heroku login
-
heroku run --app pure-inlet-98383 rake db:migrate
-
heroku run --app pure-inlet-98383 rake db:seed:destroy_all
-
heroku run --app pure-inlet-98383 rake db:seed:dev
-
heroku run --app pure-inlet-98383 rails console
- to use rails console in heroku
Ruby on Rails guides and configs
- Ruby: 2.4.0
- Rails: 5.0.1
Start server by issuing command:
rails server
By default rails will be running at localhost:3000
For tests, use rspec:
rspec spec -fd
If you don't have rspec, install it with command
bundle install