Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Download an unpack telegraf on aarch64 systems (e.g. Raspberry PI 3)
#!/usr/bin/env fish
set -x dlraw (curl --silent "" | jq -r '.body' | grep linux_arm64.tar.gz | grep -v static | head -n1 | awk -F'|' '{print $3}')
set -x version (curl --silent "" | jq -r .tag_name)
cd /tmp
wget -q (echo $dlraw | awk -F'(' '{print $2}' | tr -d ' ()') -O /tmp/(echo $dlraw | awk -F'(' '{print $1}' | tr -d ' []\`')
tar xzf /tmp/(echo $dlraw | awk -F'(' '{print $1}' | tr -d ' []\`')
rsync -r /tmp/telegraf/* /
/usr/bin/telegraf --version | grep $version
chown root:telegraf /usr/bin/telegraf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.