Rukender
Rukender

Reputation: 57

OWASP Dependency Tracker Jenkins Plugin - Connection Refused

I have installed the Dependency tracker plugin in Jenkins but when I'm trying to configure it and test the connection, it is giving an error, and an error message is also not clear to me.

error message:

Connection failed
java.net.ConnectException: Connection refused (Connection refused)
    at java.base/java.net.PlainSocketImpl.socketConnect(Native Method)
    at java.base/java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:412)
    at java.base/java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:255)
    at java.base/java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:237)
    at java.base/java.net.Socket.connect(Socket.java:609)
    at java.base/sun.net.NetworkClient.doConnect(NetworkClient.java:177)
    at java.base/sun.net.www.http.HttpClient.openServer(HttpClient.java:474)

enter image description here enter image description here

Please help me resolve this issue.

Upvotes: 0

Views: 769

Answers (1)

Paul Anand
Paul Anand

Reputation: 11

Is both Jenkins and Dependency-Track running as a container?

If so, setting the Dependency-Track URL to http://localhost:9090 will result in Jenkins attempting to connect to port 9090 on its local container.

You can try setting the Dependency-Track URL to use the IP address of the docker network interface. (e.g. http://172.17.0.1:9090)

See https://www.baeldung.com/linux/docker-connecting-containers-to-host.

Upvotes: 1

Related Questions