Commit forgotten patch to prometheus-yoctotemp-exporter
This commit is contained in:
parent
7af78934f0
commit
e22c50a5b2
1 changed files with 15 additions and 13 deletions
|
@ -4,17 +4,19 @@ VCS_TAG=$(cat "$__object/parameter/version")
|
||||||
VCS_URL="https://code.recycled.cloud/RecycledCloud/prometheus-yoctotemp-exporter/raw/tag/$VCS_TAG/prometheus-yoctotemp-exporter"
|
VCS_URL="https://code.recycled.cloud/RecycledCloud/prometheus-yoctotemp-exporter/raw/tag/$VCS_TAG/prometheus-yoctotemp-exporter"
|
||||||
|
|
||||||
cat << EOF
|
cat << EOF
|
||||||
cd /opt/prometheus-yoctotemp-exporter
|
if [ ! -d /opt/prometheus-yoctotemp-exporter ]; then
|
||||||
|
cd /opt/prometheus-yoctotemp-exporter
|
||||||
# Fetch sources.
|
|
||||||
curl "$VCS_URL" -o prometheus-yoctotemp-exporter
|
# Fetch sources.
|
||||||
|
curl "$VCS_URL" -o prometheus-yoctotemp-exporter
|
||||||
# Install virtualenv and dependencies.
|
|
||||||
virtualenv -p python3 venv
|
# Install virtualenv and dependencies.
|
||||||
. venv/bin/activate
|
virtualenv -p python3 venv
|
||||||
pip install prometheus_client
|
. venv/bin/activate
|
||||||
pip install yoctopuce
|
pip install prometheus_client
|
||||||
|
pip install yoctopuce
|
||||||
# Start service
|
|
||||||
service prometheus-yoctotemp-exporter start
|
# Start service
|
||||||
|
service prometheus-yoctotemp-exporter start
|
||||||
|
fi
|
||||||
EOF
|
EOF
|
||||||
|
|
Reference in a new issue