From 091e443c8a678b0459006531c6a0afb3f08fc09a Mon Sep 17 00:00:00 2001 From: Ashwin Vangipuram Date: Sun, 23 Aug 2020 17:53:41 -0400 Subject: [PATCH] [DOCKER] Fixing docker-compose, and not running Runtime by default Former-commit-id: 7775e56e30c90c8fd8c763877b32b18ebce95cef --- docker-compose.yml | 2 +- docker/README.md | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index bbefe0a3..b233c37e 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -6,7 +6,7 @@ services: context: . dockerfile: docker/Dockerfile image: pierobotics/runtime:latest - command: bash -c "./runtime build && ./runtime run" + command: bash -c "./runtime build && tail -f /dev/null" volumes: # Changes in local runtime/ and container /root/runtime are synced - .:/root/runtime diff --git a/docker/README.md b/docker/README.md index 910e6064..27d654a6 100644 --- a/docker/README.md +++ b/docker/README.md @@ -22,17 +22,17 @@ If you are on Windows/Mac, you will be using Docker Desktop which will already h If you are just starting out and want to get into development quickly, go to the `runtime` folder and do - docker-compose run --rm runtime bash + docker-compose up -d -which will begin a bash shell in the Docker container. From there you can call `runtime run` and the other `runtime` commands mentioned in the root README. Also, in another terminal you can do +which will start the Docker container. Now you can do docker-compose exec runtime bash -to run/test other things within the container. By default, the `runtime/` git folder and `/root/runtime` will be linked so changes in one place will also change in the other place. +to open up a bash terminal in the container. You can repeat this command to get however many bash terminals you want. From the container, you can then call `runtime run` and the other `runtime` commands mentioned in the root README. Additionally, the `runtime/` git folder and `/root/runtime` will be linked so changes in the container will also change on your machine. ## Stopping -To stop the container, just exit all your shells or do +To stop the container, do docker-compose down