Created
December 11, 2023 00:34
-
-
Save wwng2333/063b117f8d49640723e64cdf2933f449 to your computer and use it in GitHub Desktop.
neko-status
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wget https://github.com/nkeonkeo/nekonekostatus/releases/download/v0.1/neko-status -O /usr/bin/neko-status | |
mkdir /etc/neko-status/ | |
chmod +x /usr/bin/neko-status | |
echo "key: 12f6d3cb-02af-4ef6-bba4-d3f17d392f5f | |
port: 9999 | |
debug: false" > /etc/neko-status/config.yaml | |
#alpine | |
echo '#!/sbin/openrc-run | |
name="nekonekostatus" | |
command="/usr/bin/neko-status" | |
command_args="-c /etc/neko-status/config.yaml" | |
command_background="yes" | |
pidfile="${HYSTERIA_PIDFILE:-"/run/$RC_SVCNAME.pid"}" | |
depend() { | |
after sshd | |
}' > /etc/init.d/nekonekostatus | |
chmod +x /etc/init.d/nekonekostatus | |
rc-update add nekonekostatus | |
rc-service nekonekostatus start | |
#systemctl | |
echo "[Unit] | |
Description=nekonekostatus | |
[Service] | |
Restart=always | |
RestartSec=5 | |
ExecStart=/usr/bin/neko-status -c /etc/neko-status/config.yaml | |
[Install] | |
WantedBy=multi-user.target" > /etc/systemd/system/nekonekostatus.service | |
systemctl daemon-reload | |
systemctl start nekonekostatus | |
systemctl enable nekonekostatus | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment