From fe9859d959d7f08a41583c3ce77168728b4b4890 Mon Sep 17 00:00:00 2001 From: Matteo Giaccone Date: Thu, 6 Dec 2018 23:04:06 +0100 Subject: [PATCH] Docker improvements to better use existing tools --- CONTRIBUTING.md | 10 ++++++---- Dockerfile | 2 -- docker-compose.yml | 1 - 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 759c7b01..3461dc93 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -11,7 +11,7 @@ For example: - tutorials on using Tracks (user manual) ## Issues -If you think having found a problem with Tracks, first search in the [existing issues]((https://github.com/TracksApp/tracks/issues). If you cannot find it, open a new issue and try providing information on your setup and what steps are needed to reproduce the problem. +If you think having found a problem with Tracks, first search in the [existing issues](https://github.com/TracksApp/tracks/issues). If you cannot find it, open a new issue and try providing information on your setup and what steps are needed to reproduce the problem. ## Enhancements It would be great to first discuss them on the [mailing list](https://groups.google.com/group/TracksApp) so you can figure out if it could be merged or not. You may use the wiki too to describe your change if it is too big for an email. @@ -20,10 +20,12 @@ If you want to contribute an enhancement or a fix, you can: 1. [fork the project](https://help.github.com/articles/fork-a-repo) 1. [create a topic branch](http://learn.github.com/p/branching.html). -1. setup the project with [docker-compose](https://docs.docker.com/compose/) by running `docker-compose up` -1. then run `./bin/setup` to setup the first run +1. install [docker-compose](https://docs.docker.com/compose/) +1. copy `app/config/site.yml.tmpl` to `app/config/site.yml` and customize as needed +1. then with `./bin/setup` you will prepare for the first run +1. start the server with `./script/server` which will start everything you need in Docker and present Tracks at [http://0.0.0.0:3000](http://0.0.0.0:3000) 1. if you need, you can launch a Rails console with `./bin/rails c` (will run inside Docker) -1. make your changes and adds/updates relevant tests. +1. make your changes and add/update relevant tests 1. run the test suite with `./bin/rake test` (will run inside Docker) 1. commit the changes 1. send a pull request. diff --git a/Dockerfile b/Dockerfile index bef29c2f..e262e54b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,6 +11,4 @@ RUN mkdir /app/log COPY . /app/ -RUN cp /app/config/site.yml.tmpl /app/config/site.yml - EXPOSE 3000 diff --git a/docker-compose.yml b/docker-compose.yml index 093c35ff..dc2b55cf 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -9,7 +9,6 @@ services: - db-data:/var/lib/mysql web: build: . - command: rails s volumes: - ${VOLUME:-.:/app} ports: