Skip to content

Commit

Permalink
Fix Fleet install in ESXi to use the latest fleet.zip release
Browse files Browse the repository at this point in the history
  • Loading branch information
pgmcgee committed Feb 19, 2021
1 parent eedd621 commit f6a85be
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ESXi/ansible/roles/logger/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@
executable: /bin/bash
become: yes
shell: |
if [ -f "/opt/fleet" ]; then
if [ -d "/opt/fleet" ]; then
echo "[$(date +%H:%M:%S)]: Fleet is already installed"
else
cd /opt || exit 1
Expand All @@ -314,7 +314,7 @@
mysql -uroot -pkolide -e "create database kolide;"
# Always download the latest release of Fleet
curl -s https://api.github.com/repos/fleetdm/fleet/releases/latest | grep 'https://github.com' | grep "/fleet.zip" | cut -d ':' -f 2,3 | tr -d '"' | wget --progress=bar:force -i -
curl -s https://api.github.com/repos/fleetdm/fleet/releases | grep 'https://github.com' | grep "/fleet.zip" | cut -d ':' -f 2,3 | tr -d '"' | tr -d ' ' | head -1 | wget --progress=bar:force -i -
unzip fleet.zip -d fleet
cp fleet/linux/fleetctl /usr/local/bin/fleetctl && chmod +x /usr/local/bin/fleetctl
cp fleet/linux/fleet /usr/local/bin/fleet && chmod +x /usr/local/bin/fleet
Expand Down

0 comments on commit f6a85be

Please sign in to comment.