Commit 1e75ac96 authored by Alain Takoudjou's avatar Alain Takoudjou

monitor sr: add a promise to check if slapgrid succeed for the current partition

parent 82e5211f
......@@ -10,6 +10,7 @@ parts =
monitor-collect-csv-wrapper
fluentd-wrapper
monitor-base
promise-check-slapgrid
publish-connection-information
......@@ -105,6 +106,16 @@ recipe = slapos.cookbook:publish
monitor-setup-url = https://monitor.app.officejs.com/#page=settings_configurator&url=${publish:monitor-url}&username=${publish:monitor-user}&password=${publish:monitor-password}
server_log_url = ${publish:monitor-base-url}/${slap-configuration:private-hash}/
[promise-check-slapgrid]
recipe = collective.recipe.template
error-log-file = ${buildout:directory}/.slapgrid-${slap-connection:partition-id}-error.log
input = inline:#!/bin/sh
if [ -f "${:error-log-file}" ]; then
>&2 cat ${:error-log-file}
exit 1
fi
output = ${monitor-directory:promises}/slapgrid-${slap-connection:partition-id}-status
mode = 700
[slap-configuration]
recipe = slapos.cookbook:slapconfiguration.serialised
......
......@@ -32,7 +32,7 @@ mode = 0644
recipe = slapos.recipe.build:download
url = ${:_profile_base_location_}/instance-monitor.cfg.jinja2
destination = ${buildout:directory}/template-base-monitor.cfg
md5sum = 4649ce8bc496cf7560c2e994f0b332ee
md5sum = ec16fdaa0e6e13dcc7d3007908182c20
mode = 0644
[template-monitor-distributor]
......
......@@ -93,7 +93,7 @@ recipe = slapos.recipe.template:jinja2
filename = template-monitor.cfg
template = ${:_profile_base_location_}/instance-monitor.cfg.jinja2.in
rendered = ${buildout:directory}/template-monitor.cfg
md5sum = 61734742e3a01a8a1d512f491b2190cc
md5sum = 0955530291105a322f2972244caf307d
context =
key apache_location apache:location
key gzip_location gzip:location
......
......@@ -137,6 +137,7 @@ crond-folder = ${logrotate-directory:cron-entries}
logrotate-folder = ${logrotate:logrotate-entries}
promise-runner = {{ monitor_runpromise }}
promise-folder = ${directory:promises}
monitor-promise-folder = ${monitor-directory:promises}
pid-file = ${monitor-directory:pids}/monitor-bootstrap.pid
public-path-list =
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment