Repository navigation
Description
After upgrading to ghcr.io/letsencrypt/pebble:2.5.1, I am seeing the following error in our test suite:
INFO event=SendRequest url=https://localhost:14000/authZ/WKrIeCnHQULq6mp3BD0eEYTlwq7M_MInYnISVm5RmXA
INFO event=ReceivedResponse location=None body="{\n \"status\": \"invalid\",\n \"identifier\": {\n \"type\": \"dns\",\n \"value\": \"<redacted>\"\n },\n \"challenges\": [\n {\n \"type\": \"tls-alpn-01\",\n \"url\": \"https://localhost:14000/chalZ/qCiMNJz2zm1mLtYTUn9hXC4cizqg25g04UI1B2AWrjk\",\n \"token\": \"TlK9my79nS0tSjtdmugDJHWUzE6N1MdK_nMjKQrd0zU\",\n \"status\": \"invalid\",\n \"validated\": \"2024-03-19T16:51:56Z\",\n \"error\": {\n \"type\": \"urn:ietf:params:acme:error:malformed\",\n \"detail\": \"Error occurred while resolving URL \\\"<redacted>\\\": \\\"lookup <redacted> on 8.8.8.8:53: no such host\\\"\",\n \"status\": 400\n }\n }\n ],\n \"expires\": \"2024-03-19T17:51:55Z\"\n}"
This suggests that the -dnsserver setting is not honoured. As a workaround, I was able to specify a custom DNS server for the entire Docker container, but this required changing the port to 53.
After further investigation, the issue seems to be that container parameters are being ignored altogether. The following invocation should fail, but the invalid parameter goes unnoticed:
docker run ghcr.io/letsencrypt/pebble:2.5.1 abcThe container listing shows that the command is translated into /app abc:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
e1b1b497e357 ghcr.io/letsencrypt/pebble:2.5.1 "/app abc" 2 minutes ago Up 2 minutes recursing_kare
Another issue I found with the new Docker image is that it does not expose any ports, requiring users to override the ExposedPorts setting when using the Docker daemon directly. Previously, the Dockerfile contained these two lines:
EXPOSE 14000
EXPOSE 15000
Activity
mcpherrinm commentedon Mar 19, 2024
Thanks, those seen like issues we should correct.
shred commentedon Mar 22, 2024
EDIT: I'm sorry, I just realized this should rather be a new issue.
philipahlberg commentedon Mar 27, 2024
Is there anything specific you had to do to make this work? I've tried adding
dns:underpebbleincompose.yml, and appending-dns01 :53to thepebble-challtestsrvcommand, but it doesn't seem to work.tindzk commentedon Mar 27, 2024
I have not tried
pebble-challtestsrvas I am running a custom DNS server that listens on 172.17.0.1:53. Pebble is able to resolve domains when I start the container with--dns 172.17.0.1.mcpherrinm commentedon May 15, 2024
This is a pebble bug, not a container one. Positional (non
-flag arguments) are ignored by pebble and doesn't throw an error.Providing a flag properly "fails":
So it is not the source of
-dnsservernot working for youmitar commentedon May 17, 2024
I can confirm. I spent two days debugging this now. :-( Docker image for pebble does not respect anymore CLI arguments. So it is not just
-dnsserver, it ignores-configas well. Try running with-config /nonexistentand it will start. v2.3.1 does not start.Furthermore, pebble-challtestsrv Docker image also ignores CLI arguments. E.g.,
-defaultIPv4is ignored.mcpherrinm commentedon May 24, 2024
I'm sorry, but I can't replicate.
You'll need to share specific steps to reproduce.
pgporada commentedon May 24, 2024
Running challtestsrv with ports mapped:
Running pebble in a container with ports mapped:
Running an arbitrary ACME client test against pebble in a container succeeds.
You can see the random domain
atbdodijeib.combeing added to challtestsrv by pebble.Edit: I just saw that the following 2 port map lines were removed from the original
linux.Dockerfileandwindows.Dockerfilein favor ofDockerfile.releasefrom this patch. Thedocker-compose.ymldoes expose these ports, but you have to be using docker compose, not running arbitrary containers like I did above.As for
pebble-challtestsrv, flags appear to be being respected there. Take for example the output of running these various commands and noticing how they differ depending on the given flag.mitar commentedon May 27, 2024
@mcpherrinm: I am running it as:
This is how README has it documented, so with
pebblein the command.Document exposing API and management ports when not using docker-comp…
mcpherrinm commentedon May 31, 2024
Thanks, I see the problem now. I think we can both fix the Pebble CLI to error in that case, and also fix the README. In the meantime, you can remove the
pebblefrom thedocker runcommand.Reject extra command line args and fix README invocation (#467)
Remove pebble for Docker CMD