Skip to content

Commit

Permalink
update install/update scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
cmrxnn committed Jan 22, 2024
1 parent ffd4bf4 commit ae4c2d5
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/install_linux
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ echo "WARNING: Influx operates on port 3000 by default. If you need to change th
echo "Influx: Running installer in 3s";
sleep 3;

sudo apt -y install curl;
apt -y install curl;

mkdir -p /etc/influx;
curl -L -o /etc/influx/config.yml "https://raw.githubusercontent.com/cmrxnn/influx-agent/develop/config.yml.example"
Expand All @@ -13,7 +13,7 @@ curl -L -o /usr/local/bin/influx "https://github.com/cmrxnn/influx-agent/release

chmod u+x /usr/local/bin/influx;

sudo echo "[Unit]
echo "[Unit]
Description=InfluxAgent
After=network.target
Expand Down
15 changes: 15 additions & 0 deletions scripts/update_linux
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash

echo "Influx: Running updater in 3s";
sleep 3;

systemctl stop influx;
curl -L -o /usr/local/bin/influx "https://github.com/cmrxnn/influx-agent/releases/latest/download/influx_linux_$([[ "$(uname -m)" == "x86_64" ]] && echo "amd64" || echo "arm64")";

chmod u+x /usr/local/bin/influx;

systemctl restart --now influx;

echo "Influx: Update completed, checking systemctl process...";

systemctl status influx;

0 comments on commit ae4c2d5

Please sign in to comment.