run-updater-check.sh 1.1 KB

1234567891011121314151617181920212223242526272829
  1. #!/bin/sh
  2. echo ">>> Installing CI support packages..."
  3. /netdata/.github/scripts/ci-support-pkgs.sh
  4. echo ">>> Installing Netdata..."
  5. /netdata/packaging/installer/kickstart.sh --dont-wait --build-only --disable-telemetry || exit 1
  6. echo "::group::>>> Pre-Update Environment File Contents"
  7. cat /etc/netdata/.environment
  8. echo "::endgroup::"
  9. echo "::group::>>> Pre-Update Netdata Build Info"
  10. netdata -W buildinfo
  11. echo "::endgroup::"
  12. echo ">>> Updating Netdata..."
  13. export NETDATA_BASE_URL="http://localhost:8080/artifacts/" # Pull the tarball from the local web server.
  14. timeout 3600 /netdata/packaging/installer/netdata-updater.sh --not-running-from-cron --no-updater-self-update
  15. case "$?" in
  16. 124) echo "!!! Updater timed out." ; exit 1 ;;
  17. 0) ;;
  18. *) echo "!!! Updater failed." ; exit 1 ;;
  19. esac
  20. echo "::group::>>> Post-Update Environment File Contents"
  21. cat /etc/netdata/.environment
  22. echo "::endgroup::"
  23. echo "::group::>>> Post-Update Netdata Build Info"
  24. netdata -W buildinfo
  25. echo "::endgroup::"
  26. echo ">>> Checking if update was successful..."
  27. /netdata/.github/scripts/check-updater.sh || exit 1