Last active
December 13, 2016 15:49
-
-
Save artschwagerb/02a922584e716b4934b0 to your computer and use it in GitHub Desktop.
bosun scollector install
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apt-get -y install git | |
wget https://storage.googleapis.com/golang/go1.3.3.linux-amd64.tar.gz | |
tar -C /usr/local -xzf go1.3.3.linux-amd64.tar.gz | |
export PATH=$PATH:/usr/local/go/bin | |
export GOPATH=/home/linuxadmin/go | |
go get github.com/bosun-monitor/scollector | |
echo 'description "upstart job for scollector" | |
author "Brian Artschwager" | |
start on runlevel [2345] | |
stop on shutdown | |
respawn | |
respawn limit 1 5 | |
script | |
export GOPATH="/home/linuxadmin/go/" | |
exec /usr/local/go/bin/go run /home/linuxadmin/go/src/github.com/bosun-monitor/scollector/main.go -h="bosun.htps.us:8070" | |
end script' >> /etc/init/scollector.conf | |
start scollector |
Issure resolved from myself by changing the Go path.
For eg : /home/go-bk/src/bosun.org/cmd/scollector/main.go
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The Information looks Nice and also the way of explaining the step is Good. But I have tried the same steps but it is not working for me and I am suspect that it is due to scollector path issue.
In the Github the path was changed from "github.com/bosun-monitor/scollector" to "https://github.com/bosun-monitor/bosun/tree/master/cmd/scollector".
So when downloading only getting an Readme file and nothing else so the installaion gets error. In the main.go file path is imported as "bosun.org/_third_party/github.com/BurntSushi/toml" but actual path were the file is located as mentioned below:
For Example as per the my hosts: "/home/linuxadmin/go/src/github.com/bosun-monitor/bosun/cmd/scollector/main.go
So I am facing an issue while installing the scollector in linux hosts kindly update the script so that I can follow your way and install.