sozuctl, a command line interface for the sozu proxy
Sozuctl is a command line interface for the proxy. You can send configuration orders (e.g. Add a new worker) or reclaim some metrics at the proxy with this executable. Sozuctl talks to the proxy through a unix socket.
You can specify its path by adding to your config.toml
:
= "path/to/your/command_folder/sock"
Add application with http frontend
First you need to create a new application with an id and a load balancing policy (roundrobin or random):
It won't show anything but you can verify that the application has been added successfully by querying sozu:
Then you need to add a backend:
Finally you have to create a frontend to allow sozu to send traffic from the listener to your backend:
Check the status of sozu
It shows a list of workers and show informations about their statuses.
Get metrics and statistics
It will show global statistics about sozu, workers and applications metrics.
Dump and restore state
If sozu configurations (applications, frontends & backends) are not written in the config file, you can save sozu state to restore it later.
Then shutdown gracefully sozu:
Restart sozu and restore its state:
You should be able to request your application like before the shutdown.