full_install_osm.sh: minor fix, no sudo for wget node_exporter, required for installa... 36/8836/7
authorgarciadeblas <gerardo.garciadeblas@telefonica.com>
Wed, 29 Apr 2020 13:24:19 +0000 (13:24 +0000)
committergarciadeblas <gerardo.garciadeblas@telefonica.com>
Wed, 13 May 2020 14:28:45 +0000 (14:28 +0000)
Change-Id: Ibf14ea9e7c468df3b67d7eb0d855a97a41fa5250
Signed-off-by: garciadeblas <gerardo.garciadeblas@telefonica.com>
installers/full_install_osm.sh

index 5f26734..47bcdb2 100755 (executable)
@@ -322,11 +322,11 @@ function install_prometheus_nodeexporter(){
                 echo "Creating user node_exporter"
                 sudo useradd --no-create-home --shell /bin/false node_exporter
             fi
-            sudo wget -q https://github.com/prometheus/node_exporter/releases/download/v$PROMETHEUS_NODE_EXPORTER_TAG/node_exporter-$PROMETHEUS_NODE_EXPORTER_TAG.linux-amd64.tar.gz  -P /tmp/
+            wget -q https://github.com/prometheus/node_exporter/releases/download/v$PROMETHEUS_NODE_EXPORTER_TAG/node_exporter-$PROMETHEUS_NODE_EXPORTER_TAG.linux-amd64.tar.gz  -P /tmp/
             sudo tar -C /tmp -xf /tmp/node_exporter-$PROMETHEUS_NODE_EXPORTER_TAG.linux-amd64.tar.gz
             sudo cp /tmp/node_exporter-$PROMETHEUS_NODE_EXPORTER_TAG.linux-amd64/node_exporter /usr/local/bin
             sudo chown node_exporter:node_exporter /usr/local/bin/node_exporter
-            sudo rm -rf node_exporter-$PROMETHEUS_NODE_EXPORTER_TAG.linux-amd64*
+            sudo rm -rf /tmp/node_exporter-$PROMETHEUS_NODE_EXPORTER_TAG.linux-amd64*
             sudo cp ${OSM_DEVOPS}/installers/docker/prometheus/node_exporter.service /etc/systemd/system/node_exporter.service
             sudo systemctl daemon-reload
             sudo systemctl restart node_exporter