Skip to main content

[wip] Developing with Docker

Install Docker https://store.docker.com/editions/community/docker-ce-desktop-mac You will need to create an account to download it.

This command initializes the database. docker-compose run web bash docker_post_install.sh Run it once you want to clean a database.

To start the application run: docker-compose up

Application start might take up to 5 minutes, so be patient.

Open https://0.0.0.0:3002 and add certificate, then open https://localhost:3000 Tada! You have a working environment without installing Ruby, NodeJS, Postgres, etc.

It just works - Puru

All file changes made in the project folder will be also affected in Docker.

To stop it run in a different terminal tab: docker-compose down

To run rails console or any other command you need to attach to container. Run docker container ls to list all running containers. Copy CONTAINER ID of powr_web and run docker exec -it [container_id] bash to attach to the running container. Then you can run rails console or whatever you want.