3
0

Refactor NGS Pulsar role: remove obsolete files and add new task and handler definitions

This commit is contained in:
NiceDevil
2025-08-24 10:05:24 +02:00
parent c17fe406f2
commit 5d3aed6890
7 changed files with 302 additions and 12 deletions

View File

@@ -0,0 +1,26 @@
#!/sbin/openrc-run
name="ngs-pulsar"
description="Enginsight Pulsar Service"
command="{{ pulsar_install_path }}/{{ pulsar_binary_name }}"
command_args=">> /var/log/enginsight/pulsar.log 2>&1"
command_background="yes"
pidfile="/var/run/${name}.pid"
command_user="root:root"
directory="{{ pulsar_install_path }}"
depend() {
need net
use logger
after firewall
}
start_pre() {
checkpath --directory --owner root:root --mode 0755 /var/log/enginsight
checkpath --file --owner root:root --mode 0644 /var/log/enginsight/pulsar.log
[ -x "{{ pulsar_install_path }}/{{ pulsar_binary_name }}" ] || {
eerror "Binary not executable: {{ pulsar_install_path }}/{{ pulsar_binary_name }}"
return 1
}
}