Commit ba3dd231 authored by Alain Takoudjou's avatar Alain Takoudjou

monitor: check_free_disk_space promise moved to slapos.toolbox promise plugin

parent 140b987c
...@@ -78,7 +78,6 @@ scripts = ...@@ -78,7 +78,6 @@ scripts =
monitor.genstatus monitor.genstatus
monitor.configwrite monitor.configwrite
is-process-older-than-dependency-set is-process-older-than-dependency-set
check-free-disk
check-computer-memory check-computer-memory
[monitor-eggs] [monitor-eggs]
......
...@@ -34,7 +34,6 @@ scripts = ...@@ -34,7 +34,6 @@ scripts =
monitor.genstatus monitor.genstatus
monitor.configwrite monitor.configwrite
is-process-older-than-dependency-set is-process-older-than-dependency-set
check-free-disk
[extra-eggs] [extra-eggs]
recipe = zc.recipe.egg recipe = zc.recipe.egg
......
...@@ -14,4 +14,4 @@ ...@@ -14,4 +14,4 @@
# not need these here). # not need these here).
[monitor2-template] [monitor2-template]
filename = instance-monitor.cfg.jinja2.in filename = instance-monitor.cfg.jinja2.in
md5sum = b30c47a593299da9889035850a47c519 md5sum = a2da18b7e1d4ae1332e19e5d1b70fcdf
...@@ -88,7 +88,7 @@ parameter-file-path = ${monitor-instance-parameter:configuration-file-path} ...@@ -88,7 +88,7 @@ parameter-file-path = ${monitor-instance-parameter:configuration-file-path}
parameter-list = parameter-list =
raw monitor-user ${monitor-instance-parameter:username} raw monitor-user ${monitor-instance-parameter:username}
htpasswd monitor-password ${httpd-monitor-htpasswd:password-file} ${monitor-instance-parameter:username} ${httpd-monitor-htpasswd:htpasswd-path} htpasswd monitor-password ${httpd-monitor-htpasswd:password-file} ${monitor-instance-parameter:username} ${httpd-monitor-htpasswd:htpasswd-path}
file min-free-disk-MB ${promise-check-free-disk-space:config-file} file min-free-disk-MB ${promise-check-free-disk-space:config-threshold-file}
${monitor-instance-parameter:instance-configuration} ${monitor-instance-parameter:instance-configuration}
# htpasswd entry: htpasswd key password-file username htpasswd-file # htpasswd entry: htpasswd key password-file username htpasswd-file
...@@ -377,13 +377,15 @@ config-monitor-url = ${monitor-instance-parameter:monitor-base-url} ...@@ -377,13 +377,15 @@ config-monitor-url = ${monitor-instance-parameter:monitor-base-url}
mode = 600 mode = 600
[promise-check-free-disk-space] [promise-check-free-disk-space]
recipe = slapos.cookbook:wrapper recipe = slapos.cookbook:promise.plugin
command-line = {{ check_disk_space }} eggs =
--collectordb ${monitor-instance-parameter:collector-db} slapos.toolbox
--home_path ${buildout:directory} output = ${directory:plugins}/check-free-disk-space.py
--config ${:config-file} content =
wrapper-path = ${directory:promises}/check-free-disk-space from slapos.promise.plugin.check_free_disk_space import RunPromise
config-file = ${directory:etc}/min-free-disk-size mode = 600
config-collectordb = ${monitor-instance-parameter:collector-db}
config-threshold-file = ${directory:etc}/min-free-disk-size
[monitor-base] [monitor-base]
......
  • @alain.takoudjou since this commit SLAPOS-CADDY-FRONTEND-MASTER fails, as promise/check-free-disk-space is not available in monitored instances anymore.

    Are there are actions to take in order to have check-free-disk-space promise available on the profile level? Before it was coming from using monitor.

  • Łukasz Nowak @luke

    mentioned in merge request !389 (merged)

    ·

    mentioned in merge request !389 (merged)

    Toggle commit list
  • Ok, I confirmed that it can be detected now by presence of etc/promise/check-free-disk-space.py, I will fix assertions.

  • @luke yes, etc/promise/check-free-disk-space was replaced by etc/plugin/check-free-disk-space.py. Thanks for updating.

    All new promises should be writen like that.

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