In my last post Ill explain how to run your PHP code every second using bash/shell script but once you close terminal it will terminate. Now if you want your script to run continuously in background you can run bellow command

Run shell script in background after terminal close

To stop running shell script run bellow command

To check all running process run bellow command

Hope this command help you 🙂