Download the PHP package nikoutel/tritonsysteminfoapi without Composer
On this page you can find all versions of the php package nikoutel/tritonsysteminfoapi. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package tritonsysteminfoapi
TritonSystemInfoAPI
A Restful API to get the representations of system information and metrics.
Get system information (like OS, hostname, public IPs, services status), metrics (like CPU usage, free memory, web server load), and even configurations (like apache2.conf and php.ini) with an easy to navigate and configurable RESTfull web-service, made with Lumen.
Triton
adopts the HAL
(Hypertext Application Language) convention for representing resources and their relations with hypermedia links.
Resources are formatted in JSON and have the media type "application/hal+json"
Only the GET
http method is implemented, other methods are not allowed.
Status
Current status: It works on my machine!
Meaning: It is still under development, and for now only Debian Gnu/Linux
systems with systemd
are supported.
It should work on other Debian
based systems (with systemd
) but they are not fully tested yet.
Warning!!
This will expose critical information about your system! Use it wisely!
Information/metrics - Endpoints
- System
- Information -
/api/system/info
- Load average -
/api/system/load
- CPU -
/api/system/cpu
- Info -
/api/system/cpu/info
- Extended info -
/api/system/cpu/extended-info
- Usage (%) -
/api/system/cpu/usage
- Info -
- Network -
/api/system/network
- Info -
/api/system/network/info
- Usage (KiB/Sec) -
/api/system/network/usage
- Info -
- Memory -
/api/system/memory
- Usage -
/api/system/memory/usage
- Usage -
- Disk -
/api/system/disk
- Info -
/api/system/disk/info
- Usage -
/api/system/disk/usage
- Info -
- Information -
- Services -
/api/services
- {Service} - e.g.
/api/services/apache2
,/api/services/mysql
- Info - e.g.
/api/services/apache2/info
- Status - e.g.
/api/services/apache2/status
- Load - e.g.
/api/services/apache2/load
- Config - e.g.
/api/services/apache2/config
- {Config} - e.g.
/api/services/apache2/config/sites-enabled
,/api/services/mysql/mysql/config/my.conf
- {Config} - e.g.
- Info - e.g.
- {Service} - e.g.
- Software -
/api/system/software
- php -
/api/system/software/php
- phpinfo -
/api/system/software/php/phpinfo
- Config -
/api/system/software/php/config
- {Config} - e.g.
/api/system/software/php/config/php.ini
,/api/system/software/php/config/php.ini-cli
- {Config} - e.g.
- phpinfo -
- php -
Services
An environment variable (ALLOWED_SERVICES
) defined in the .env
file, controls which services are allowed to be processed.
Any other service will result in a 404 error.
Configs
Similar, an environment variable (ALLOWED_CONF
), controls which configurations are allowed.
Dynamically defined allowed services, which also have allowed configurations defined,
must be included in the TYPES_WITH_SEC_PARAMETER
environment variable,
and their configurations must be defined with the ALLOWED_CONF{service_name}
(e.g. ALLOWED_CONFAPACHE2
) environment variable.
Configuration paths are defined via the PATH_{conf_name}
variable (e.g. PATH_MYCNF=/etc/mysql/my.cnf
).
Requirements
- PHP 7.1.3 (min)
Install
composer:
As standalone:
As library:
Configuration
Create an .env
configuration file (if not available) according to .env.example
.
The .env file stores environment variables for the application.
Environment variable names consist solely of uppercase letters, digits, and the '_' (underscore) (IEEE Std 1003.1-2001)
License
This software is licensed under the MPL 2.0:
All versions of tritonsysteminfoapi with dependencies
laravel/lumen-framework Version 5.8.*
jenssegers/model Version ^1.2
nikoutel/helionconfig Version ^2.0
ext-json Version *