About
Pulse is a client-server network communication project.
A containerized client collects monitoring data and reports it to a
containerized server.
Both are POSIX-compliant shell
(Portable Operating System Interface for uniX) scripts built on the Unix
shell framework shellbase.
Objectives
Both the client and the server run on the alpine base image.
Every five seconds the client sends the following data to the server:
-
Host uptime
-
Host network interface names and IP addresses
The server stores the received data in a database. After every five status updates, the server sends a kill signal to restart the client service.
Build and Start
To build and start the containers with Podman Compose:
# Starts VM.
podman machine start
# Builds both images and starts containers.
podman-compose up --build
# Stops and removes containers.
podman-compose down
# Stops VM.
podman machine stop
Test
The project uses Daniel J. Bernstein’s build system redo.
You can install Sergey Matveev’s goredo implementation.
redo lint applies the following linters to the source files:
actionlint,
hadolint,
reuse,
shellcheck,
shfmt,
typos,
yamllint,
zizmor.
It also parses each script with dash and mksh to reject syntax the
project’s target shells do not accept.
License
pulse belongs to David Rabkin and uses a
Zero-Clause BSD license.