https://github.com/josestg/sigterm
A subset of the syscall package for terminating processes. This package provides a Signal type that implements the encoding.TextMarshaller and encoding.TextUnmarshaler interfaces for text-based serialization and deserialization.
https://github.com/josestg/sigterm
12factorapp config golang graceful-shutdown
Last synced: about 1 month ago
JSON representation
A subset of the syscall package for terminating processes. This package provides a Signal type that implements the encoding.TextMarshaller and encoding.TextUnmarshaler interfaces for text-based serialization and deserialization.
- Host: GitHub
- URL: https://github.com/josestg/sigterm
- Owner: josestg
- License: mit
- Created: 2024-08-23T06:00:51.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-08-24T04:28:13.000Z (8 months ago)
- Last Synced: 2025-01-31T06:47:01.920Z (3 months ago)
- Topics: 12factorapp, config, golang, graceful-shutdown
- Language: Go
- Homepage:
- Size: 2.93 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# sigterm
A subset of the `syscall` package for terminating processes. This package provides a `Signal` type that implements
the `encoding.TextMarshaller` and `encoding.TextUnmarshaler` interfaces for text-based serialization and deserialization.
It can be used for configuration management using environment variables[^env_caarlos0] or flags [^flag].List of termination signals can be found in the GNU libc manual [^gnu_manual].
## Installation
```bash
go get -u github.com/josestg/sigterm
```[^flag]: https://golang.org/pkg/flag/#TextVar
[^env_caarlos0]: https://github.com/caarlos0/env
[^gnu_manual]: https://www.gnu.org/software/libc/manual/html_node/Termination-Signals.html