Skip to content

Commit

Permalink
Create deploy.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
gayeon1025 authored Apr 15, 2024
1 parent 42eab09 commit 40757b2
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions deploy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/bash

SERVER_HOME=$(pwd)
APPLICATION=devlog_springboot-0.0.1-SNAPSHOT.jar

if [ -f $SERVER_HOME/application.pid ];then
kill -9 $(cat $SERVER_HOME/application.pid)
rm $SERVER_HOME/application.pid
fi

sleep 1s

nohup java -jar $APPLICATION >> spring.out 2>&1 & echo $! > application.pid

0 comments on commit 40757b2

Please sign in to comment.