]> git.ipfire.org Git - thirdparty/systemd.git/commit
import: Support env var to override gpg keyring
authorKai Lüke <kai@amutable.com>
Wed, 29 Apr 2026 06:06:32 +0000 (15:06 +0900)
committerKai Lüke <kai@amutable.com>
Wed, 1 Jul 2026 13:00:48 +0000 (22:00 +0900)
commite50f4b7387451f30569feff66997d434ea84263d
tree16329d5fa3770350d7b10911a4becfb6a999babf
parent8b8d819944b6713bcb8b05d8e643c21de3770d08
import: Support env var to override gpg keyring

By default there is a fixed keyring in /usr or /etc. But when running
systemd-pull unprivileged in the user context or with a custom transfer
definition as in systemd-sysupdate --definitions=./... (e.g., for local
ParticleOS updates) it is limiting to require that all keys have to be
part of the OS keyring or otherwise no verification can be used. Also,
for testing it is valuable to point it at a different keyring.
Add a SYSTEMD_OPENPGP_KEYRING env var where the omission or empty
assignment sticks to the current behavior of the global OS keyrings but
a keyring path given will take precedence. While an env var can leak
down the process tree and is more difficult to secure for being the
trust anchor the advantage is that one can directly specify it in the
service unit as drop-in instead of having to patch the command
invocation. Anyway it's a niche use case and thus not part of the man
page.
docs/ENVIRONMENT.md
src/import/pull-common.c