environment file
A file of name=value lines that a systemd service loads into its process environment with EnvironmentFile=.
In more detail
It keeps application settings apart from the unit that supervises the process, so you can change one without editing the other. Protect it with file permissions if it contains anything sensitive, because environment variables leak easily into logs and child processes.
Related terms
- environment variable — A named setting such as PORT=8000 that a program reads from its surroundings when it starts.
- systemd service — A systemd unit that describes a long-running or one-shot process: what command to run, as which user and what to do when it exits.
- unit file — The text file, in a simple key=value format with sections such as [Unit], [Service] and [Install], that declares a systemd unit.
Taught in
- Your Own Unit, And Reading journald — Linux Fundamentals & Systems Administration