Fix ci
This MR closes #59 (closed) and #60 (closed)
- updates the docker-compose file so that
ink
and all depended on services can be started with a single command - fixes a failing test
- adds gitlab-ci config for ci (closes #59 (closed))
- adds option to log to stdout
Commands
- development:
docker-compose up
- test (mounts project as volume):
./scripts/test
. This command will pass its arguments through torspec
. - gitlab-ci locally:
gitlab-runner exec docker --docker-volumes /var/run/docker.sock:/var/run/docker.sock --env CI_COMMIT_SHA=<a-tag-of-an-image-on-the-local-machine> test
. - production: do not use docker-compose (kubernetes templates will be added)
Further notes:
- Seeds for development are run from
./bin/rake setup
(cf. #62). - Scripts have been tidied up a bit. Those to be run inside containers are in
bin
(plus some others whose purpose is unclear). Those to be run on the host are inscript
. - test and development rails envs no longer force
POSTGRESQL_HOST
=localhost
(bc docker requirespostgres
), butlocalhost
will be the default.
Test
The failing test was testing that loading a file had failed to load a class not defined in that file. Unfortunately the class had sometimes been loaded elsewhere, depending on test execution order.
Logging
Set RAILS_LOG_TO_STDOUT=1
to log to stdout instead of file.
Edited by Sam Galson