From 7e2352ab57ad94d34df39484b0885e3bef1970c9 Mon Sep 17 00:00:00 2001 From: Marcela Rosales Date: Fri, 29 Jun 2018 12:45:16 -0500 Subject: [PATCH] Enabling detach mode in tb.sh for run command This in order to get the shell back after executing run and don't need another terminal session. Story: 2002753 Change-Id: I2f65fe9d6cc4b2284bdf766b0a2ff3a6643f23d1 Signed-off-by: Marcela Rosales --- README.md | 6 ++---- tb.sh | 1 + 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3ec7b0c1..93a7aeeb 100644 --- a/README.md +++ b/README.md @@ -94,10 +94,7 @@ By default `LOCALDISK` will be placed under the directory pointed to by `HOST_PR which defaults to `$HOME/starlingx`. The `tb.sh` script uses sub-commands to select the operation: -* `run` - Runs the container in a shell. This does not return to a shell prompt while - the container is running, you will need another shell window to work inside the - container. This allows systemd and thus mock, to work from within the container. - It will also create `LOCALDISK` if it does not exist. +* `run` - Runs the container in a shell. It will also create `LOCALDISK` if it does not exist. * `stop` - Kills the running shell. * `exec` - Starts a shell inside the container. @@ -121,6 +118,7 @@ or by hand: ``` docker run -it --rm \ --name ${TC_CONTAINER_NAME} \ + --detach \ -v ${LOCALDISK}:${GUEST_LOCALDISK} \ -v ${HOST_MIRROR_DIR}:/import/mirrors:ro \ -v /sys/fs/cgroup:/sys/fs/cgroup:ro \ diff --git a/tb.sh b/tb.sh index 42b77501..83137054 100755 --- a/tb.sh +++ b/tb.sh @@ -37,6 +37,7 @@ function run_container { docker run -it --rm \ --name ${TC_CONTAINER_NAME} \ + --detach \ -v ${LOCALDISK}:/${GUEST_LOCALDISK} \ -v ${HOST_MIRROR_DIR}:/import/mirrors:ro \ -v /sys/fs/cgroup:/sys/fs/cgroup:ro \