1, the installation
sudo apt-get install supervisor
2, if the report phthond2.7 error, perform
easy_install supervisor
3, the profile and the location profile examples
Profile location / etc / supervisor / own custom configuration files are placed /etc/supervisor/conf.d directory
; Identify the name of the program, when the terminal needs to control [Program: mposAPI] ; command to run the program in the Command = DOTNET mposAPI.dll ; command execution directory Directory = / Home / mposAPI ; quit unexpectedly restart automatically autorestart is = to true ; the implementation process user identity the user = root ; the error log files needed to create log directory stderr_logfile = / Home / mposAPI / log / err.log ; output log file stdout_logfile = / Home / mposAPI / log / OUT .log ; process environment variables environment = ASPNETCORE_ENVIRONMENT =Production stopsignal=INT
4, related commands
// start the service
sudo supervisord
Re-record the profile
supervisorctl reload
enable a service
supervisorctl Start mposAPI
supervisorctl STOP mposAPI
stop all
supervisorctl stop all
starts all
supervisorctl start all