Skip to content

ShreyasMahen/bash-rule-manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bash Rule Manager — Graceful Shutdown Demo

This project demonstrates how to implement graceful shutdown in Bash using signal handling (trap) and cleanup functions.

Behavior

  • The script writes a timestamp to /tmp/graceful.state every 5 seconds.
  • When Ctrl-C is pressed, it deletes the temp file and exits cleanly.

Run

./scripts/graceful.sh Press ⇧ Ctrl-C to see cleanup.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages