diff --git a/CMakeLists.txt b/CMakeLists.txt index 47510b4371..e48f3908cf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2641,11 +2641,13 @@ install(PROGRAMS COMPONENT netdata DESTINATION usr/libexec/netdata/plugins.d) -install(PROGRAMS - src/health/notifications/alarm-email.sh - src/health/notifications/alarm-test.sh - COMPONENT netdata - DESTINATION usr/libexec/netdata/plugins.d) +if(CMAKE_BUILD_TYPE STREQUAL "Debug") + install(PROGRAMS + src/health/notifications/alarm-email.sh + src/health/notifications/alarm-test.sh + COMPONENT netdata + DESTINATION usr/libexec/netdata/plugins.d) +endif() install(FILES src/health/notifications/health_alarm_notify.conf @@ -2656,22 +2658,23 @@ install(FILES # test/ files # -configure_file(tests/health_mgmtapi/health-cmdapi-test.sh.in tests/health_mgmtapi/health-cmdapi-test.sh @ONLY) -configure_file(tests/acls/acl.sh.in tests/acls/acl.sh @ONLY) -configure_file(tests/urls/request.sh.in tests/urls/request.sh @ONLY) -configure_file(tests/alarm_repetition/alarm.sh.in tests/alarm_repetition/alarm.sh @ONLY) -configure_file(tests/template_dimension/template_dim.sh.in tests/template_dimension/template_dim.sh @ONLY) -configure_file(tests/ebpf/ebpf_thread_function.sh.in tests/ebpf/ebpf_thread_function.sh @ONLY) - -install(FILES - ${CMAKE_BINARY_DIR}/tests/health_mgmtapi/health-cmdapi-test.sh - ${CMAKE_BINARY_DIR}/tests/acls/acl.sh - ${CMAKE_BINARY_DIR}/tests/urls/request.sh - ${CMAKE_BINARY_DIR}/tests/alarm_repetition/alarm.sh - ${CMAKE_BINARY_DIR}/tests/template_dimension/template_dim.sh - ${CMAKE_BINARY_DIR}/tests/ebpf/ebpf_thread_function.sh - DESTINATION usr/libexec/netdata/plugins.d) +if(CMAKE_BUILD_TYPE STREQUAL "Debug") + configure_file(tests/health_mgmtapi/health-cmdapi-test.sh.in tests/health_mgmtapi/health-cmdapi-test.sh @ONLY) + configure_file(tests/acls/acl.sh.in tests/acls/acl.sh @ONLY) + configure_file(tests/urls/request.sh.in tests/urls/request.sh @ONLY) + configure_file(tests/alarm_repetition/alarm.sh.in tests/alarm_repetition/alarm.sh @ONLY) + configure_file(tests/template_dimension/template_dim.sh.in tests/template_dimension/template_dim.sh @ONLY) + configure_file(tests/ebpf/ebpf_thread_function.sh.in tests/ebpf/ebpf_thread_function.sh @ONLY) + install(FILES + ${CMAKE_BINARY_DIR}/tests/health_mgmtapi/health-cmdapi-test.sh + ${CMAKE_BINARY_DIR}/tests/acls/acl.sh + ${CMAKE_BINARY_DIR}/tests/urls/request.sh + ${CMAKE_BINARY_DIR}/tests/alarm_repetition/alarm.sh + ${CMAKE_BINARY_DIR}/tests/template_dimension/template_dim.sh + ${CMAKE_BINARY_DIR}/tests/ebpf/ebpf_thread_function.sh + DESTINATION usr/libexec/netdata/plugins.d) +endif() # # charts.d plugin # diff --git a/netdata.spec.in b/netdata.spec.in index 74fe03b186..67d7de4a08 100644 --- a/netdata.spec.in +++ b/netdata.spec.in @@ -527,22 +527,14 @@ rm -rf "${RPM_BUILD_ROOT}" %{_libexecdir}/%{name}/install-service.sh %{_libexecdir}/%{name}/%{name}-updater.sh %{_libexecdir}/%{name}/%{name}-uninstaller.sh -%{_libexecdir}/%{name}/plugins.d/acl.sh -%{_libexecdir}/%{name}/plugins.d/alarm.sh -%{_libexecdir}/%{name}/plugins.d/alarm-email.sh %{_libexecdir}/%{name}/plugins.d/alarm-notify.sh -%{_libexecdir}/%{name}/plugins.d/alarm-test.sh %{_libexecdir}/%{name}/plugins.d/anonymous-statistics.sh %{_libexecdir}/%{name}/plugins.d/cgroup-name.sh %{_libexecdir}/%{name}/plugins.d/get-kubernetes-labels.sh -%{_libexecdir}/%{name}/plugins.d/health-cmdapi-test.sh %{_libexecdir}/%{name}/plugins.d/ioping.plugin %{_libexecdir}/%{name}/plugins.d/loopsleepms.sh.inc -%{_libexecdir}/%{name}/plugins.d/request.sh %{_libexecdir}/%{name}/plugins.d/system-info.sh %{_libexecdir}/%{name}/plugins.d/tc-qos-helper.sh -%{_libexecdir}/%{name}/plugins.d/template_dim.sh -%{_libexecdir}/%{name}/plugins.d/ebpf_thread_function.sh # cgroup-network detects the network interfaces of CGROUPs # it must be able to use setns() and run cgroup-network-helper.sh as root