Closed nirmalpathak closed 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
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/
That makes sense, could you create a PR?
Closing as this is fixed in #37. Please reopen if issue is still present.
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:
$ go version
go version go1.13.8 linux/amd64
$ which go
/usr/bin/go