mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-07-09 23:47:38 +00:00
[core] Rebase Scripts (formatting, highlighting & remove old deps) (#3378)
* Big Refactor: Remove Deps / Formatting & Correct End Of Line Sequence * f
This commit is contained in:
@ -5,7 +5,7 @@
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/lissy93/web-check
|
||||
|
||||
source /dev/stdin <<< "$FUNCTIONS_FILE_PATH"
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
@ -16,9 +16,6 @@ update_os
|
||||
msg_info "Installing Dependencies"
|
||||
export DEBIAN_FRONTEND=noninteractive
|
||||
$STD apt-get -y install --no-install-recommends \
|
||||
curl \
|
||||
sudo \
|
||||
mc \
|
||||
git \
|
||||
gnupg \
|
||||
traceroute \
|
||||
@ -67,7 +64,7 @@ $STD npm install -g yarn
|
||||
msg_ok "Installed Node.js"
|
||||
|
||||
msg_info "Setting up Chromium"
|
||||
/usr/bin/chromium --no-sandbox --version > /etc/chromium-version
|
||||
/usr/bin/chromium --no-sandbox --version >/etc/chromium-version
|
||||
chmod 755 /usr/bin/chromium
|
||||
msg_ok "Setup Chromium"
|
||||
|
||||
@ -78,7 +75,7 @@ wget -q "https://github.com/CrazyWolf13/web-check/archive/refs/heads/${RELEASE}.
|
||||
tar xzf $temp_file
|
||||
mv web-check-${RELEASE} /opt/web-check
|
||||
cd /opt/web-check
|
||||
cat <<'EOF' > /opt/web-check/.env
|
||||
cat <<'EOF' >/opt/web-check/.env
|
||||
CHROME_PATH=/usr/bin/chromium
|
||||
PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium
|
||||
HEADLESS=true
|
||||
@ -109,7 +106,7 @@ $STD yarn build --production
|
||||
msg_ok "Built Web-Check"
|
||||
|
||||
msg_info "Creating Service"
|
||||
cat <<'EOF' > /opt/run_web-check.sh
|
||||
cat <<'EOF' >/opt/run_web-check.sh
|
||||
#!/bin/bash
|
||||
SCREEN_RESOLUTION="1280x1024x24"
|
||||
if ! systemctl is-active --quiet dbus; then
|
||||
@ -123,7 +120,7 @@ cd /opt/web-check
|
||||
exec yarn start
|
||||
EOF
|
||||
chmod +x /opt/run_web-check.sh
|
||||
cat <<'EOF' > /etc/systemd/system/web-check.service
|
||||
cat <<'EOF' >/etc/systemd/system/web-check.service
|
||||
[Unit]
|
||||
Description=Web Check Service
|
||||
After=network.target
|
||||
|
Reference in New Issue
Block a user