From 8ce3a46ad5c88ffa1f864e498a8c40b7c27c03b9 Mon Sep 17 00:00:00 2001 From: Etienne Tremel Date: Tue, 13 Mar 2018 22:40:16 +0000 Subject: [PATCH] Add missing -L flag when using curl command to download release --- CHANGELOG.md | 10 ++++++++++ Makefile | 6 +++--- install.sh | 8 ++++---- plugin.yaml | 2 +- 4 files changed, 18 insertions(+), 8 deletions(-) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..e12d3f3 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,10 @@ +Changelog +========= + +## v0.1.1 + +- install.sh: add missing `-L` flag to curl command and do not rely on bash + +## v0.1.0 + +- Initial release diff --git a/Makefile b/Makefile index 7391fd4..72a2ebd 100644 --- a/Makefile +++ b/Makefile @@ -17,11 +17,11 @@ build: dist: mkdir -p $(DIST) GOOS=linux GOARCH=amd64 go build -o $(BINARY) -ldflags $(LDFLAGS) ./cmd/... - tar -zcvf $(DIST)/helm-monitor_linux_$(VERSION).tgz $(BINARY) README.md LICENSE plugin.yaml + tar -zcvf $(DIST)/helm-monitor_linux_$(VERSION).tar.gz $(BINARY) README.md LICENSE plugin.yaml GOOS=darwin GOARCH=amd64 go build -o $(BINARY) -ldflags $(LDFLAGS) ./cmd/... - tar -zcvf $(DIST)/helm-monitor_darwin_$(VERSION).tgz $(BINARY) README.md LICENSE plugin.yaml + tar -zcvf $(DIST)/helm-monitor_darwin_$(VERSION).tar.gz $(BINARY) README.md LICENSE plugin.yaml GOOS=windows GOARCH=amd64 go build -o $(BINARY).exe -ldflags $(LDFLAGS) ./cmd/... - tar -zcvf $(DIST)/helm-monitor_windows_$(VERSION).tgz $(BINARY).exe README.md LICENSE plugin.yaml + tar -zcvf $(DIST)/helm-monitor_windows_$(VERSION).tar.gz $(BINARY).exe README.md LICENSE plugin.yaml test-all: vet lint test diff --git a/install.sh b/install.sh index 2696ff3..07ad4ea 100755 --- a/install.sh +++ b/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/sh set -e @@ -7,7 +7,7 @@ HELM_MONITOR_VERSION=${HELM_MONITOR_VERSION:-$current_version} dir=${HELM_PLUGIN_DIR:-"$(helm home)/plugins/helm-monitor"} os=$(uname -s | tr '[:upper:]' '[:lower:]') -release_file="helm-monitor_${os}_${HELM_MONITOR_VERSION}.tgz" +release_file="helm-monitor_${os}_${HELM_MONITOR_VERSION}.tar.gz" url="https://github.com/ContainerSolutions/helm-monitor/releases/download/v${HELM_MONITOR_VERSION}/${release_file}" mkdir -p $dir @@ -16,10 +16,10 @@ if command -v wget then wget -O ${dir}/${release_file} $url elif command -v curl; then - curl -o ${dir}/${release_file} $url + curl -L -o ${dir}/${release_file} $url fi -tar xf ${dir}/${release_file} -C $dir +tar xvf ${dir}/${release_file} -C $dir chmod +x ${dir}/helm-monitor diff --git a/plugin.yaml b/plugin.yaml index 4657da7..5356fda 100644 --- a/plugin.yaml +++ b/plugin.yaml @@ -1,6 +1,6 @@ --- name: "monitor" -version: "0.1.0" +version: "0.1.1" usage: "monitor and rollback in case of failure based on metrics or logs" description: |- Query at a given interval a Prometheus or ElasticSearch instance, a rollback