Skip to content

Commit e797cba

Browse files
authored
fix: fix default java version (#2286)
1 parent ecc2949 commit e797cba

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

install/crafty-controller-install.sh

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,14 @@ $STD apt-get install -y \
2626
software-properties-common
2727
msg_ok "Installed Dependencies"
2828

29-
msg_info "Setting up TermurinJDK"
29+
msg_info "Setting up TemurinJDK"
3030
mkdir -p /etc/apt/keyrings
3131
wget -qO - https://packages.adoptium.net/artifactory/api/gpg/key/public | tee /etc/apt/keyrings/adoptium.asc
3232
echo "deb [signed-by=/etc/apt/keyrings/adoptium.asc] https://packages.adoptium.net/artifactory/deb $(awk -F= '/^VERSION_CODENAME/{print$2}' /etc/os-release) main" | tee /etc/apt/sources.list.d/adoptium.list
3333
$STD apt-get update
34-
$STD apt-get install -y \
35-
temurin-8-jre \
36-
temurin-11-jre \
37-
temurin-17-jre \
38-
temurin-21-jre \
39-
temurin-23-jre
34+
$STD apt-get install -y temurin-{8,11,17,21}-jre
4035
sudo update-alternatives --set java /usr/lib/jvm/temurin-21-jre-amd64/bin/java
41-
msg_ok "Installed TermurinJDK"
36+
msg_ok "Installed TemurinJDK"
4237

4338
msg_info "Setup Python3"
4439
$STD apt-get install -y \
@@ -49,7 +44,6 @@ $STD apt-get install -y \
4944
rm -rf /usr/lib/python3.*/EXTERNALLY-MANAGED
5045
msg_ok "Setup Python3"
5146

52-
5347
msg_info "Installing Craty-Controller (Patience)"
5448
useradd crafty -m -s /bin/bash
5549
cd /opt
@@ -81,7 +75,7 @@ After=network.target
8175
Type=simple
8276
User=crafty
8377
WorkingDirectory=/opt/crafty-controller/crafty/crafty-4
84-
Environment=PATH=/opt/crafty-controller/crafty/.venv/bin:$PATH
78+
Environment=PATH=/usr/lib/jvm/temurin-21-jre-amd64/bin:/opt/crafty-controller/crafty/.venv/bin:$PATH
8579
ExecStart=/opt/crafty-controller/crafty/.venv/bin/python3 main.py -d
8680
Restart=on-failure
8781

0 commit comments

Comments
 (0)