--- - fail: msg="Option 'services.grafana.configFile' has to be set!" when: - services.grafana.configFile is not defined - fail: msg="Option 'services.grafana.dashboards' has to be set when using provisioning!" when: - services.grafana.provisioning.enable is true - services.grafana.provisioning.dashboards is not defined - fail: msg="Option 'services.grafana.datasources' has to be set when using provisioning!" when: - services.grafana.provisioning.enable is true - services.grafana.provisioning.datasources is not defined - fail: msg="Nginx role has to be enabled when using nginx options!" when: - services.grafana.nginx.enable is true - services.nginx.enable is false - fail: msg="Option 'services.grafana.nginx.domain' has to be set when using nginx!" when: - services.grafana.nginx.enable is defined - services.grafana.nginx.enable is true - services.grafana.nginx.domain is not defined - fail: msg="Option 'services.grafana.nginx.sslOnly' has to be set when using nginx!" when: - services.grafana.nginx.enable is defined - services.grafana.nginx.enable is true - services.grafana.nginx.sslOnly is not defined - fail: msg="Option 'services.grafana.nginx.ssl.cert' has to be set when using nginx with ssl!" when: - services.grafana.nginx.enable is defined - services.grafana.nginx.enable is true - services.grafana.nginx.ssl.enable is defined - services.grafana.nginx.ssl.enable is true - services.grafana.nginx.ssl.cert is not defined - fail: msg="Option 'services.grafana.nginx.ssl.privkey' has to be set when using nginx with ssl!" when: - services.grafana.nginx.enable is defined - services.grafana.nginx.enable is true - services.grafana.nginx.ssl.enable is defined - services.grafana.nginx.ssl.enable is true - services.grafana.nginx.ssl.privkey is not defined