Halo, kalau kamu merasa tulisan saya ngebantu kamu, kamu bisa ucapkan terima kasih lewat saweria .

Hello, if you find this article helpful, you can express your gratitude through saweria .



Tools yang Digunakan

  1. Ubuntu 22.04 LTS

  2. Supervisord 4.2.1


How To

  1. Masuk ke direktori /etc/supervisor/conf.d cd /etc/supervisor/conf.d

  2. Buat 1 file baru, octane.conf

[program:octane]
#autorestart=true
autostart=true
user=ipang
group=www-data
#redirect_stderr=true
command=php8.2 /home/ipang/laravel/artisan octane:start --port 4000 --host 0.0.0.0
port=4000
stopwaitsecs=3600
stdout_logfile=/var/log/supervisor/custom-log/web-event-out.log
stderr_logfile=/var/log/supervisor/custom-log/web-event-err.log
  1. Jalankan sudo supervisorctl reread && sudo supervisorctl update

Beberapa command/parameter di supervisorctl

#list semua service
sudo supervisorctl status

#tail log service
sudo supervisorctl tail -f nama-service
sudo supervisorctl tail -100 nama-service


#stop service
sudo supervisorctl stop nama-service

#start service
sudo supervisorctl start nama-service

Post lain yang mungkin bermanfaat buat kamu

  1. Cara setup Logrotate Supervisor