From e99815e5e932dcb19cfc86307699751b1fcd8f18 Mon Sep 17 00:00:00 2001 From: mike dupont Date: Sun, 22 Dec 2024 07:50:42 -0500 Subject: [PATCH] adding in the new install for systemd and nginx from swarms. we will move this out into ssm files we can apply on boot later --- api/just_run.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/api/just_run.sh b/api/just_run.sh index d0e7ed4e..3e11dc4a 100644 --- a/api/just_run.sh +++ b/api/just_run.sh @@ -49,6 +49,11 @@ echo "HOME=${ROOT}/home/swarms" >> "${ROOT}/var/run/swarms/secrets/env" # attempt to move the workspace echo 'WORKSPACE_DIR=${STATE_DIRECTORY}' >> "${ROOT}/var/run/swarms/secrets/env" +# setup the systemd service again +sed -e "s!ROOT!${ROOT}!g" > /etc/nginx/sites-enabled/default < "${WORKSOURCE}/nginx/site.conf" +sed -e "s!ROOT!${ROOT}!g" > /etc/systemd/system/swarms-uvicorn.service < "${WORKSOURCE}/systemd/uvicorn.service" +grep . -h -n /etc/systemd/system/swarms-uvicorn.service + chown -R swarms:swarms ${ROOT}/var/run/swarms/ mkdir -p ${ROOT}/opt/swarms/api/agent_workspace/try_except_wrapper/ chown -R swarms:swarms ${ROOT}/opt/swarms/api/