script_exporter
script_exporter copied to clipboard
Can't start as windows service
Service don't start with nssm. Anybody can start it succesfull?

Hi @kissaev, sorry for the late reply. I think the following should work:
# Create a service named "script_exporter"
sc create script_exporter binpath="%CD%\script_exporter-windows-amd64.exe -config.file=%CD%\config.yaml" start=auto DisplayName="script_exporter"
sc description script_exporter "Prometheus exporter to execute scripts and collect metrics from the output or the exit status."
# Start / stop the "script_exporter" service
net start script_exporter
net stop script_exporter
# Show current state of the "script_exporter" service
sc query script_exporter
# Delete the "script_exporter" service
sc delete script_exporter
Since I'm not on windows, I do not know if the same works for nssm.
I would close the issue for now, if you have further questions please let me know.