prometheus / demo-site

Demo site auto-deployed with Ansible and Travis CI.
Apache License 2.0
102 stars 58 forks source link

TASK [Copy random_exporter binary] fails. #32

Closed nirmalpathak closed 4 years ago

nirmalpathak commented 4 years ago

Issue: The ansible playbook fails to copy random export binary.

Error: TASK [Copy random_exporter binary] ** An exception occurred during task execution. To see the full traceback, use -vvv. The error was: If you are using a module and expect the file to exist on the remote, see the remote_src option fatal: [demo]: FAILED! => {"changed": false, "msg": "Could not find or access 'random'\nSearched in:\n\t/home/ubuntu/demo-site/playbooks/files/random\n\t/home/ubuntu/demo-site/playbooks/random\n\t/home/ubuntu/demo-site/playbooks/files/random\n\t/home/ubuntu/demo-site/playbooks/random on the Ansible Controller.\nIf you are using a module and expect the file to exist on the remote, see the remote_src option"}

Details:

paulfantom commented 4 years ago

random_exporter is built before running ansible playbook. You can see full deployment scenario in https://github.com/prometheus/demo-site/blob/master/.circleci/config.yml

nirmalpathak commented 4 years ago

I think the README should be updated to manually run go command to download & copy the 'random' exporter binary to "demo-site/playbooks/files location".

I did the following & it worked.

$ go get -u github.com/prometheus/client_golang/examples/random
$ cp ~/go/bin/random demo-site/playbooks/files/
paulfantom commented 4 years ago

That makes sense, could you create a PR?

paulfantom commented 4 years ago

Closing as this is fixed in #37. Please reopen if issue is still present.