Alignak-monitoring-contrib / alignak-backend

Backend for alignak (REST API for configuration, retention, livestate, logs) based on Python Eve
GNU Affero General Public License v3.0
11 stars 4 forks source link

Host/service templates check_command inheritance #503

Open mohierf opened 6 years ago

mohierf commented 6 years ago

If an inherited host/service template do not define a check_command the created host/service do not have any check command and it gets the default host/service check command.

The expected behavior is to have the check_command defined in one of the base templates!

For instance, inheriting from two templates should provide the check_command of the tempalte which has one defined check_command

mohierf commented 6 years ago

Indeed, the templates list order is of many importance for this ! The host will inherit the last template check_command even if it is set to None! Then it will be replaced with the default host check_command defined in the backend ...

mohierf commented 6 years ago

When needing to inherit from multiple templates: