1
0
HTTP service that returns a list of process' names with boolean values that respectively telling us if process is running or not. For UNIX-like OS only.
Go to file
2023-02-04 20:42:24 +04:00
build/archlinux Version was changed to 2.0.1. Description was changed. 2023-02-04 20:42:24 +04:00
configs Config file moved to configs dir. 2022-10-10 00:08:48 +04:00
init Systemd service file was moved to init dir. Program renamed. Added all security tweaks used in other projects. 2022-10-10 00:06:35 +04:00
.gitignore Added executable to .gitignore. 2022-10-10 00:03:40 +04:00
configuration.go Added some more comments. 2023-02-04 20:33:26 +04:00
errors.go Code was restructurised again. Moved out back to root dir. 2022-01-02 21:30:56 +04:00
go.mod For no particular reason version of go was upped to 1.20. 2023-02-04 20:35:53 +04:00
httpserver.go server.go -> httpserver.go. 2022-10-10 00:11:17 +04:00
LICENSE License is switched to MIT+NIGGER. :) 2022-01-02 05:13:20 +04:00
main.go Version was changed to 2.0.1. Description was changed. 2023-02-04 20:42:24 +04:00
Makefile Removed unused SYSCTL line from Makefile. 2023-02-04 20:36:18 +04:00
proc.go In GetProcessPIDs() var pids was moved to return values. Added a comment. 2023-02-04 20:35:23 +04:00
processlist.go Added some more comments. 2023-02-04 20:33:26 +04:00
README.md Program renamed. Version was changed to 2.0.0. Fixed typo. Corrected installation section and link to PKGBUILD. 2022-10-10 00:12:16 +04:00

httpprocprobed Ver 2.0.0

License: MIT+NIGGER.

This utility provides a HTTP /processes GET endpoint that returns a list of processes, and if they are currently running or not.

There are currently three output formats available: JSON, XML, plain text.

JSON is a default format if Accept header didn't provided, or did with value application/json. Its form is {"process":true|false, ...}.

XML is provided if Accept: application/xml header was given. Its form is <ProcessList><Process name="process">true|false</Process>...</ProcessList>.

Plain text is provided if Accept: text/plain header was given. Its form is a comma separated list of ONLY running process' names.

Configuration file is a simple key = value storage consisting of listen_address string field in form "[<ip|host>]:<port>". indented_output bool in form true|false, to enable indentation of JSON and XML output. And processes is a space separated array of process names.

Installation

Manually

Run these commands one after the other.

$ make
$ make install

In order to uninstall run these commands:

# systemctl stop httpprocprobed
# systemctl disable httpprocprobed
$ make uninstall
# systemctl daemon-reload

For ArchLinux

You can take a PKGBUILD file and in a directory with it run makepkg -i.