Skip to content

Commit

Permalink
Merge pull request #3273 from dodona-edu/update-readme
Browse files Browse the repository at this point in the history
Update readme to improve setup script for new users
  • Loading branch information
jorg-vr authored Jan 10, 2022
2 parents d4c22f9 + 87d9751 commit 96c6769
Showing 1 changed file with 15 additions and 9 deletions.
24 changes: 15 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,19 @@ If you want to help with development, issues tagged with the [student label](htt
3. Create a `dodona` user with access to the `dodona` and `dodona_test-N` databases. You will need as much test databases as hou have CPU threads.
```sql
CREATE USER 'dodona'@'localhost' IDENTIFIED BY 'dodona';
GRANT ALL ON dodona.* TO 'dodona';
GRANT ALL ON dodona_test.* TO 'dodona';
GRANT ALL ON dodona_test-0.* TO 'dodona';
GRANT ALL ON dodona.* TO 'dodona'@'localhost';
GRANT ALL ON dodona_test.* TO 'dodona'@'localhost';
GRANT ALL ON `dodona_test-0`.* TO 'dodona'@'localhost';
...
GRANT ALL ON dodona_test-3.* TO 'dodona';
GRANT ALL ON `dodona_test-N`.* TO 'dodona'@'localhost';
```
4. Create and seed the database with `rails db:setup`. (If something goes wrong with the database, you can use `rails db:reset` to drop, rebuild and reseed the database.)
4. Install the correct `ruby` version using [RVM](https://rvm.io/)
5. Install the correct `node` version using `nvm` and [yarn](https://yarnpkg.com/)
6. Run `bundle install` and `yarn install`
7. Create and seed the database with `rails db:setup`. (If something goes wrong with the database, you can use `rails db:reset` to drop, rebuild and reseed the database.)
If the error "Could not initialize python judge" arises, use `SKIP_PYTHON_JUDGE=true rails db:setup`
5. [Start the server](#starting-the-server). The simplest way is with `rails s`. Dodona [will be available on a subdomain of localhost](#localhost-subdomain): http://dodona.localhost:3000.
6. Because CAS authentication does not work in development, you can log in by going to these pages (only works with the seed database from step 4)
8. [Start the server](#starting-the-server). The simplest way is with `rails s`. Dodona [will be available on a subdomain of localhost](#localhost-subdomain): http://dodona.localhost:3000.
9. Because CAS authentication does not work in development, you can log in by going to these pages (only works with the seed database from step 4)
- `http://dodona.localhost:3000/nl/users/1/token/zeus`
- `http://dodona.localhost:3000/nl/users/2/token/staff`
- `http://dodona.localhost:3000/nl/users/3/token/student`
Expand All @@ -55,8 +58,11 @@ If the error "Could not initialize python judge" arises, use `SKIP_PYTHON_JUDGE=
These steps are not required to run the server, but you need docker to actually evaluate exercises.
1. Install and start `docker`.
2. Clone the [docker-images repository](https://github.com/dodona-edu/docker-images).
3. Build a docker image. The `build.sh` scripts builds all images. But with the initial data, only `dodona-python` is needed. You can build this image with `docker build --pull --force-rm -t "dodona-python" -f "dodona-python.dockerfile" .`.
2. Run `docker pull dodona/dodona-python`
If you want to build the docker images yourself:
1. Clone the [docker-images repository](https://github.com/dodona-edu/docker-images).
2. Build a docker image. The `build.sh` scripts builds all images. But with the initial data, only `dodona-python` is needed. You can build this image with `docker build --pull --force-rm -t "dodona-python" -f "dodona-python.dockerfile" .`.
#### Loading visualisations locally
These steps are not required to run the server, but are needed to let the visualisations load.
Expand Down

0 comments on commit 96c6769

Please sign in to comment.