|
||||||||||||||
This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators. For more information on JIRA, see: http://www.atlassian.com/software/jira |
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Same problem: cli works when accessing the server directly, but not when accessed via an nginx proxy.
Jenkins version 1.593. No configuration done before testing cli, so everything is default. jenkins-cli.jar newly downloaded from this jenkins. Cli tests done on the jenkins server.
Jenkins is running directly (without container), installed and started as:
$ wget http://mirrors.jenkins-ci.org/war/1.593/jenkins.war
$ /usr/bin/java -Xms256m -Xmx1024m -DJENKINS_HOME=/home/esusedl/.jenkins-sjk2 -jar /home/esusedl/.jenkins-sjk2/jenkins.war --httpPort=8080 --httpsPort=8081 --ajp13Port=-1 --prefix=/sjk2
When using cli towards the server directly it works fine:
$ /usr/bin/java -jar jenkins-cli.jar -s https://jenkins_server_fqdn:8081/jenkins -noCertificateCheck version
Skipping HTTPS certificate checks altogether. Note that this is not secure at all.
Enter passphrase for /home/myuser/.ssh/id_rsa:
[WARN] Failed to authenticate with your SSH keys. Proceeding as anonymous
1.593
$ /usr/bin/java -jar jenkins-cli.jar -s https://jenkins_proxy_fqdn/jenkins -noCertificateCheck version
Skipping HTTPS certificate checks altogether. Note that this is not secure at all.
Enter passphrase for /home/myuser/.ssh/id_rsa:
Exception in thread "main" java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:579)
at hudson.cli.CLI.connectViaCliPort(CLI.java:203)
at hudson.cli.CLI.<init>(CLI.java:126)
at hudson.cli.CLIConnectionFactory.connect(CLIConnectionFactory.java:72)
at hudson.cli.CLI._main(CLI.java:466)
at hudson.cli.CLI.main(CLI.java:382)
Suppressed: java.io.EOFException: unexpected stream termination
at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:331)
at hudson.remoting.Channel.<init>(Channel.java:421)
at hudson.remoting.Channel.<init>(Channel.java:400)
at hudson.remoting.Channel.<init>(Channel.java:396)
at hudson.remoting.Channel.<init>(Channel.java:385)
at hudson.remoting.Channel.<init>(Channel.java:377)
at hudson.remoting.Channel.<init>(Channel.java:353)
at hudson.cli.CLI.connectViaHttp(CLI.java:157)
at hudson.cli.CLI.<init>(CLI.java:130)
... 3 more
$ /usr/bin/java -version
java version "1.7.0_45"
Java(TM) SE Runtime Environment (build 1.7.0_45-b18)
Java HotSpot(TM) 64-Bit Server VM (build 24.45-b08, mixed mode)
Jenkins server: RHEL 6.5 x86_64 with a self-signed certificate.
Jenkins proxy server: RHEL 6.5 x86_64 with a verisign certificate. Nginx config for the jenkins instance:
location /jenkins { sendfile off; proxy_pass https://jenkins_server_fqdn:8081/jenkins; proxy_set_header Host $http_host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; }