Search

Gradle On Ubuntu

Gradle On Ubuntu

gradle ์„ค์น˜

sudo apt install gradle
Bash
๋ณต์‚ฌ

์„ค์น˜ ํ™•์ธ

gradle -v
Bash
๋ณต์‚ฌ

git clone

git clone https://github.com/ALOHA-CLASS/HelloSpringBoot.git
Bash
๋ณต์‚ฌ

ํ”„๋กœ์ ํŠธ ๋นŒ๋“œ

cd ~~~/project
Bash
๋ณต์‚ฌ
โ€ข
ํŒŒ์ผ ๊ถŒํ•œ ๋ณ€๊ฒฝ
chmod 777 ./gradlew
Bash
๋ณต์‚ฌ
โ€ข
build.gradle, gradlew ๊ฒฝ๋กœ๋กœ ์ด๋™ํ•œ ๋’ค,
./gradlew bootWar
Bash
๋ณต์‚ฌ

lib/~.war ๋ฐฐํฌ ํŒŒ์ผ ์‹คํ–‰

cd ~~~/lib
Bash
๋ณต์‚ฌ
java -jar ~~~.war
Bash
๋ณต์‚ฌ
java -jar hello-0.0.1-SNAPSHOT.war
Bash
๋ณต์‚ฌ

๋ฐฑ๊ทธ๋ผ์šด๋“œ์—์„œ ์„œ๋ฒ„ ์‹คํ–‰

nohup java -jar ~~~.war
Bash
๋ณต์‚ฌ
nohup java -jar hello-0.0.1-SNAPSHOT.war &
Bash
๋ณต์‚ฌ

๋ฐฑ๊ทธ๋ผ์šด์Šค์—์„œ ์‹คํ–‰ํ•œ ์„œ๋ฒ„ ์ข…๋ฃŒ

โ€ข
ํ”„๋กœ์„ธ์Šค ์•„์ด๋”” ํ™•์ธ
pgrep -f [ํ”„๋กœ์„ธ์Šค]
Bash
๋ณต์‚ฌ
pgrep -f hello-0.0.1-SNAPSHOT.war
Bash
๋ณต์‚ฌ
โ€ข
ํ”„๋กœ์„ธ์Šค ์ข…๋ฃŒ
kill [PID]
Bash
๋ณต์‚ฌ
kill 86580
Bash
๋ณต์‚ฌ