8000 GitHub - R4j4n/TVs
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

R4j4n/TVs

Repository files navigation

I'll create a shell script to safely stop the API service.

Save this script as stop_api_service.sh in the same directory as your other scripts. Here's how to use it:

  1. Make it executable:
chmod +x stop_api_service.sh
  1. To stop the service:
./stop_api_service.sh
  1. To stop the service AND prevent it from starting on next reboot:
./stop_api_service.sh --disable-autostart

The script will:

  1. Check if the API service is running
  2. Send a graceful termination signal (Ctrl+C) to your Python process
  3. Wait a moment for clean shutdown
  4. Kill the tmux session
  5. Optionally remove it from crontab if you use the --disable-autostart flag

If you ever need to check the status before stopping:

tmux ls

This will show you if the api_service session is running.

Would you like me to explain any part of this script in more detail?

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
0