testcontainers / testcontainers/testcontainers-java

Can not connect to Ryuk at localhost:49154

Aperta
#5,122 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Lingua principale
Java
Stelle
8.7k
Fork
1.9k
Merge medio
2g 17h
PR unite (30g)
9

Descrizione

Dear all,

I'm running testcontainers on Windows and Linux (WSL2).
On both systems I get since some days the following error when I try to use test containers.
I'm using Docker Desktop 4.5.1 (74721)

The following logs are from Ubuntu (WSL2):

12:47:43.495 [testcontainers-ryuk] WARN  o.t.utility.ResourceReaper - Can not connect to Ryuk at localhost:49154
java.net.ConnectException: Connection refused: connect

When I run ryuk on its own, I get this

$ docker run quay.io/testcontainers/ryuk
2022/02/25 12:43:56 Starting on port 8080...
panic: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

goroutine 1 [running]:
main.main()
        /go/src/github.com/testcontainers/moby-ryuk/main.go:31 +0xe2e

Here the docker logs of the container when I run it with mvn test:

$ docker logs 4fed1346fccd
2022/02/25 12:52:38 Starting on port 8080...

I get the same output when I run the stuff on windows.

If I look at the line starting with panic:

panic: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

As I'm using Docker Desktop, there is no such pipe, but you could use tcp://0.0.0.0:2375 to connect to docker.
But it seems in the past testcontainer had no issue with that. I'm not sure what was updated, so that it is now broken.
Is it possible to tell ryuk to use the tcp URL instead of the unix pipe?

Best regards,
Dieter

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Direzione di ricerca

Inizia riproducendo il malfunzionamento con mvn test ed esamina ResourceReaper di Testcontainers insieme all’entry point di Ryuk menzionato in main.go:31. Verifica come viene fornito l’endpoint Docker su Windows e WSL2; il lavoro è completato quando Ryuk si connette correttamente e l’esecuzione dei test non segnala più il rifiuto di localhost:49154.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
docker, java
Ambito
devops, testing
Tipo di issue
Bug
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Da chiarire
Idoneità per principianti
20/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.