You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 24, 2021. It is now read-only.
Today the docker-agent returns 0 every time as exit code. This is a little bit annoying because the caller cannot detect when an error was generated by the docker agent:
java exception
or errors (not green status) detected during policies checking or other checks.
Hi
Just checked with the latest version & as some exceptions are catched in some deeper methods & not thrown upper, the error code is still 0 & cannot be managed in a clean way
[INFO] Using proxy: proxy:8080
[INFO] Checking policies
[ERROR] Failed to send request to WhiteSource server: errno: 111 (Connection refused), error: Connection refused (local port 60712 to address 10.97.25.202, remote port 8080 to address 147.204.6.136 (proxy))
org.whitesource.agent.client.WssServiceException: errno: 111 (Connection refused), error: Connection refused (local port 60712 to address 10.97.25.202, remote port 8080 to address 147.204.6.136 (proxy))
at org.whitesource.agent.client.WssServiceClientImpl.service(WssServiceClientImpl.java:240) ~[docker-agent.jar:na]
at org.whitesource.agent.client.WssServiceClientImpl.checkPolicyCompliance(WssServiceClientImpl.java:151) ~[docker-agent.jar:na]
at org.whitesource.agent.client.WhitesourceService.checkPolicyCompliance(WhitesourceService.java:164) ~[docker-agent.jar:na]
at org.whitesource.agent.CommandLineAgent.checkPolicies(CommandLineAgent.java:156) [docker-agent.jar:na]
at org.whitesource.agent.CommandLineAgent.sendRequest(CommandLineAgent.java:112) [docker-agent.jar:na]
at org.whitesource.agent.CommandLineAgent.sendRequest(CommandLineAgent.java:79) [docker-agent.jar:na]
at org.whitesource.docker.Main.main(Main.java:68) [docker-agent.jar:na]
Caused by: java.net.ConnectException: errno: 111 (Connection refused), error: Connection refused (local port 60712 to address 10.97.25.202, remote port 8080 to address 147.204.6.136 (proxy))
at java.net.PlainSocketImpl.socketConnect(Native Method) ~[na:1.8.0_92]
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350) ~[na:1.8.0_92]
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) ~[na:1.8.0_92]
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) ~[na:1.8.0_92]
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) ~[na:1.8.0_92]
at java.net.Socket.connect(Socket.java:591) ~[na:1.8.0_92]
at org.apache.http.conn.scheme.PlainSocketFactory.connectSocket(PlainSocketFactory.java:117) ~[docker-agent.jar:na]
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:177) ~[docker-agent.jar:na]
at org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:304) ~[docker-agent.jar:na]
at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:611) ~[docker-agent.jar:na]
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:446) ~[docker-agent.jar:na]
at org.apache.http.impl.client.AbstractHttpClient.doExecute(AbstractHttpClient.java:882) ~[docker-agent.jar:na]
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:71) ~[docker-agent.jar:na]
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:220) ~[docker-agent.jar:na]
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:164) ~[docker-agent.jar:na]
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:139) ~[docker-agent.jar:na]
at org.whitesource.agent.client.WssServiceClientImpl.service(WssServiceClientImpl.java:218) ~[docker-agent.jar:na]
... 6 common frames omitted
[Pipeline] echo
Scanning returned value: 0
Thx in advance
Best regards
Louis
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi,
Today the docker-agent returns 0 every time as exit code. This is a little bit annoying because the caller cannot detect when an error was generated by the docker agent:
Maybe something like this could be done:
Thx in advance a lot to take into consideration this proposal
Best regards
Louis
The text was updated successfully, but these errors were encountered: