You are not logged in.
Hi,
(Apologies in advance as I'm sure this info is documented somewhere and I promise I've spent a significant time already trying to work this out on my own, I'm just not 100% sure what exactly I want to do, which makes it hard to search for a solution. So I was wondering if anyone could point me in the right direction.)
Essentially, I have a load of systemd user services running that require credentials encrpyted with gpg via pass. When a service runs, I'm prompted via a pinentry popup to enter my gpg key passphrase, this is then sucessfully cached.. somehow.. (either via the gpg-agent max-cache-ttl conf or via gnome-keyring, which also seems to have entries that look like they might be cached unlocks. This is one of thei things I'm a bit unsure of in terms of how it's working)
Anyway, once a service has been run, the cache works fine for a reasonable amount of time. The problem is, I have that many of them running that I'm bombarded with pinentry popups fairly regularly.
My assumption is that each service has its own cache? Hence the multiple popups, so I was wondering (assuming that is indeed the case) if there was a way to group a selection of systemd services in such a way that they can reference the same cache/key unlock?
Thanks in advance to anyone that takes the time to help ![]()
Last edited by ceuk (2022-05-04 09:35:14)
Offline
Make a "master service" that runs an action requesting your pinentry and have all others depend/require on that one would be my first approach.
Offline
Ok so I created a service that just run pass to trigger the pinentry popup and then referenced it in "Requires" in the other services. I've not had any more pinentry popups in the 3-4 hours of using my machine since so I think it might actually have worked! Can't believe it was so simple.
Will add a solved tag for now. Thanks V1del
Offline