Skip to content

Commit a8aec28

Browse files
committed
deploy yaml, sh 수정
1 parent bf7bdce commit a8aec28

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

.github/workflows/deploy.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,6 @@ jobs:
44
build:
55
name: Build
66
runs-on: ubuntu-latest
7-
env:
8-
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
97
steps:
108
- name: executing remote ssh commands using password using ssh-actions
119
uses: appleboy/ssh-action@v0.1.10

sh/deploy.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
#!/bin/bash
22

3+
# 에러 발생 시 스크립트 중단
4+
set -e
5+
36
git pull;
47

58
for pid in $(ps -ef | grep streamlit | grep -v grep | awk '{print $2}'); do
@@ -8,7 +11,7 @@ for pid in $(ps -ef | grep streamlit | grep -v grep | awk '{print $2}'); do
811
done
912

1013
SRC=/work/TASTY/ai
11-
DEST=/$HOME/deploy
14+
DEST=$HOME/deploy
1215

1316
rm -rf $DEST
1417
mkdir -p $DEST
@@ -22,4 +25,4 @@ source .venv/bin/activate
2225

2326
pip install -r requirements.txt
2427

25-
nohup setsid streamlit run app.py --server.port=8501 > streamlit.log 2>&1 < /dev/null &
28+
nohup ./.venv/bin/streamlit run app.py --server.port=8501 > streamlit.log 2>&1 & disown

0 commit comments

Comments
 (0)