EasyGnuPG / egpg

Easy GnuPG, shell scripts to make GnuPG more accessible and easier to use. (Migrated to: https://gitlab.com/EasyGnuPG/egpg)
GNU General Public License v3.0
26 stars 5 forks source link

Tests do not work for the non-root user inside the docker container #83

Open dashohoxha opened 6 years ago

dashohoxha commented 6 years ago

They work for the root user but fail for the developer user.

I have localized the problem to this error:

$ gpg --list-secret-keys
gpg: can't connect to the agent: IPC connect call failed

When it is called with sudo it works:

$ sudo gpg --list-secret-keys
gpg: WARNING: unsafe ownership on homedir '/home/developer/.gnupg'
/home/developer/.gnupg/pubring.kbx
----------------------------------
sec   rsa4096/18D1DA4D9E7A4FD0 2016-05-14 [SC] [expires: 2026-07-27]
      A9446F790F9BE7C9D108FC6718D1DA4D9E7A4FD0
uid                 [ultimate] Test 1 <test1@example.org>
ssb   rsa4096/12A2B2669B636DD4 2016-05-14 [E] [expires: 2026-07-27]
dashohoxha commented 6 years ago

@diveshuttam can you try ds inject run-tests.sh? Does it work for you? Now it seems to work for me, and I have not changed anything. This is strange.

diveshuttam commented 6 years ago

I tried I am also finding errors as yours while running the ds inject run-tests.sh though inside the container i am able to run gpg --list-secret-keys after su developer.

dashohoxha commented 6 years ago

If t03-init.t works, that's Ok. Because it was failing right there, and trying to locate the problem I found that gpg --list-secret-keys was not working as expected.

diveshuttam commented 6 years ago

No my t03 init doesn't work. I am looking into this- mostly there is a problem with the permissions on the files in .egpg/.gnupg.

It gives the same errors as you listed above: gpg: can't connect to the agent: IPC connect call failed