Nidonocu
Nidonocu

Reputation: 12618

Laravel Sail Up never finishes building during GPG command

I'm trying to setup the dev environment for an existing project on another computer under WSL2 and Windows 10. Having installed the project from its own repo with composer install and making sure a basic .env file is in place, I ran /vendor/bin/sail up to do the initial build.

Docker starts normally, but then during stage 4 of 11 RUN apt-get update && apt-get install...., it just halts when it gets to the line gpg: keybox '/root/.gnupg/pubring.kbx' created the build halts, the clock is still ticking but the operation never finishes.

I'm able to hit Ctrl + C and it Cancels cleanly.

Editing Laravel's dockerfile, I added a -v to the gpg --recv-key ... line in the script and got additional output with the operation halting after gpg: connection to dirmngr established instead.

I'm running Ubuntu under WSL2, fully updated, docker freshly installed and configured to talk to it as on my other machine where I'm not having any issues.

Upvotes: 4

Views: 4457

Answers (1)

witti
witti

Reputation: 151

Removing the portnumber (:80) for the keyserver from the PHP 8.x docker file seems to be a workaround for this problem.

 echo "keyserver hkp://keyserver.ubuntu.com" >> ~/.gnupg/dirmngr.conf \

Tested with PHP 8.1.

Source: https://github.com/laravel/sail/issues/503#issuecomment-1336273951

Upvotes: 14

Related Questions