From 61a19e3fe29807705eb1ea514f6fc2ca64ad0541 Mon Sep 17 00:00:00 2001 From: muskit <15199219+muskit@users.noreply.github.com> Date: Sat, 20 Apr 2024 12:28:22 -0700 Subject: [PATCH] revise scripts --- scripts/build.sh | 4 +++- scripts/run.sh | 3 ++- scripts/run_detached.sh | 3 ++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/scripts/build.sh b/scripts/build.sh index 8a36b64..22020e6 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -1,3 +1,5 @@ #!/bin/sh -sudo docker build -t nijiholo_bot "$(dirname `realpath "$0"`)/.." \ No newline at end of file +CURPATH="$(dirname `realpath "$0"`)/.." +sudo docker build -t nijiholo_bot "$CURPATH" +sudo docker container create -v "$CURPATH/run:/app/run" --name bot nijiholo_bot diff --git a/scripts/run.sh b/scripts/run.sh index 3356e3d..1ceaf84 100755 --- a/scripts/run.sh +++ b/scripts/run.sh @@ -2,4 +2,5 @@ CURPATH="$(dirname `realpath "$0"`)/.." cd "$CURPATH" mkdir -p run -sudo docker run -v "$CURPATH/run:/app/run" --name bot -it nijiholo_bot \ No newline at end of file +#sudo docker run -v "$CURPATH/run:/app/run" --name bot -it nijiholo_bot +sudo docker container start -a -i bot diff --git a/scripts/run_detached.sh b/scripts/run_detached.sh index c605946..95d14f7 100755 --- a/scripts/run_detached.sh +++ b/scripts/run_detached.sh @@ -2,4 +2,5 @@ CURPATH="$(dirname `realpath "$0"`)/.." cd "$CURPATH" mkdir -p run -sudo docker run -v "$CURPATH/run:/app/run" --name bot -d nijiholo_bot +#sudo docker run -v "$CURPATH/run:/app/run" --name bot -d nijiholo_bot +sudo docker container start bot