Merge remote-tracking branch 'upstream/main'

This commit is contained in:
Sam Heinz
2024-08-22 19:08:47 +10:00
12 changed files with 112 additions and 176 deletions
+11 -7
View File
@@ -19,6 +19,7 @@ $STD apt-get install -y sudo
$STD apt-get install -y mc
$STD apt-get install -y wget
$STD apt-get install -y openssh-server
$STD apt-get install -y rsync
msg_ok "Installed Dependencies"
msg_info "Installing Azul Zulu"
@@ -29,11 +30,14 @@ $STD apt-get update
$STD apt-get -y install zulu17-jdk
msg_ok "Installed Azul Zulu"
msg_info "Installing CommaFeed"
mkdir /opt/commafeed && cd /opt/commafeed
wget -q https://github.com/Athou/commafeed/releases/latest/download/commafeed.jar
wget -q https://github.com/Athou/commafeed/releases/latest/download/config.yml.example -O config.yml
msg_ok "Installed CommaFeed"
RELEASE=$(curl -sL https://api.github.com/repos/Athou/commafeed/releases/latest | grep '"tag_name":' | cut -d'"' -f4)
msg_info "Installing CommaFeed ${RELEASE}"
mkdir /opt/commafeed
wget -q https://github.com/Athou/commafeed/releases/download/${RELEASE}/commafeed-${RELEASE}-h2-jvm.zip
unzip -q commafeed-${RELEASE}-h2-jvm.zip
mv commafeed-${RELEASE}-h2/* /opt/commafeed/
echo "${RELEASE}" >/opt/${APPLICATION}_version.txt
msg_ok "Installed CommaFeed ${RELEASE}"
msg_info "Creating Service"
cat <<EOF >/etc/systemd/system/commafeed.service
@@ -42,7 +46,7 @@ Description=CommaFeed Service
After=network.target
[Service]
ExecStart=/usr/bin/java -Djava.net.preferIPv4Stack=true -jar /opt/commafeed/commafeed.jar server /opt/commafeed/config.yml
ExecStart=java -jar quarkus-run.jar
WorkingDirectory=/opt/commafeed/
Restart=always
@@ -56,7 +60,7 @@ motd_ssh
customize
msg_info "Cleaning up"
rm -rf zulu-repo_1.0.0-3_all.deb
rm -rf commafeed-${RELEASE}-h2 commafeed-${RELEASE}-h2-jvm.zip zulu-repo_1.0.0-3_all.deb
$STD apt-get -y autoremove
$STD apt-get -y autoclean
msg_ok "Cleaned"