Re: [JCasC] can i utilize variables?

2020-07-24 Thread j
Thank you, Ivan and Mark.  I shall try your recommendation.  :) 

Regards,
J


On Friday, July 24, 2020 at 10:24:13 AM UTC-7, Mark Waite wrote:
>
> In case it helps, here is an example that sets the Jenkins URL 
> 
>  
> based on an environment variable set from the script that launches it 
> 
> .
>
> On Fri, Jul 24, 2020 at 9:58 AM Ivan Fernandez Calvo  > wrote:
>
>> Hi,
>>
>> You can use environment variables inside of your JCasC file. If you need 
>> something more complicated you can use a Jinja template and 
>> https://github.com/kolypto/j2cli to make the transformation to YAML
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Jenkins Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to jenkins...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/a8d4e976-1d2d-4638-8ce3-69df6d86e9d6o%40googlegroups.com
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/918d16a7-b2bb-4894-b61e-fba615e59535o%40googlegroups.com.


Re: [JCasC] can i utilize variables?

2020-07-24 Thread j
Thank you, Phillip.  I shall try your recommendation.  :) 

Regards,
J


On Friday, July 24, 2020 at 1:52:53 PM UTC-7, Phillip Bailey wrote:
>
> Hi, 
>
> Jinja templates are great for such use. However, if you fancy something 
> more "exotic", go templates are something worth a go. 
>
> https://github.com/hairyhenderson/gomplate 
>
>
> Phillip 
>
>
>
> On 24/07/2020 16:57, Ivan Fernandez Calvo wrote: 
> > Hi, 
> > 
> > You can use environment variables inside of your JCasC file. If you need 
> something more complicated you can use a Jinja template and 
> https://github.com/kolypto/j2cli to make the transformation to YAML 
> > 
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/00cc7b74-2724-41a8-ba0c-ef446b109a75o%40googlegroups.com.


Re: [JCasC] can i utilize variables?

2020-07-24 Thread j
Thank you Nigel.  I shall try your recommendation.  :) 

Regards,
J

On Friday, July 24, 2020 at 2:55:48 AM UTC-7, nigel.a...@braincorp.com 
wrote:
>
> I don't believe JCasC support variables in the yaml, but in our project we 
> use jsonnet  to be able to template or use 
> variables in the creation of the casc.
>
> -Nigel
>
> On Thursday, July 23, 2020 at 1:59:41 PM UTC-7 j wrote:
>
>> Hi!
>>
>> I am new to this.  I have been trying to figure out a way to utilize 
>> variables in the yaml file.
>>
>> Help.
>>
>> Regards,
>> J
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/0eaea33b-999f-448e-81bf-9efa6a1897f2o%40googlegroups.com.


Re: [JCasC] can i utilize variables?

2020-07-24 Thread Phillip Bailey
Hi,

Jinja templates are great for such use. However, if you fancy something
more "exotic", go templates are something worth a go.

https://github.com/hairyhenderson/gomplate


Phillip



On 24/07/2020 16:57, Ivan Fernandez Calvo wrote:
> Hi,
> 
> You can use environment variables inside of your JCasC file. If you need 
> something more complicated you can use a Jinja template and 
> https://github.com/kolypto/j2cli to make the transformation to YAML
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/2d18883c-1d1b-47b8-3946-70fc76be0cc3%40bailey.st.


Re: parallel jobs not starting with docker workflow

2020-07-24 Thread Marco Sacchetto
I'm replying to myself, in case this helps anybody else. This seems to be 
triggered by having a (valid) global variable defined for agents in 
Jenkin's main configuration. Once removed, things started working as 
expected.

Il giorno venerdì 24 luglio 2020 alle 18:32:44 UTC+1 Marco Sacchetto ha 
scritto:

> Hi,
>
> I've been trying (with no result for now) to define a parallel declarative 
> pipeline such as this:
> ```
> pipeline{
> agent any
> stages {
> stage('Configure projects') {
> parallel {
> stage('Configure 1') {
> agent {
> docker {
> image ''
> alwaysPull true
> }
> steps { . }
> }
>   stage('Configure 2') {
>   
>   }
>}
>   }
> ...
> ```
> I'm uncurring in an issue that is very similar to 
> https://issues.jenkins-ci.org/browse/JENKINS-46831 , with the big 
> question mark due that 
> the bug there is from 2017 and our plugins are updated.
> The build arrives up to the parallel closure, and it spins up the parallel
> jobs in other available agents. At that point it gets stuck. On blueocean
> it seems stuck at the docker pull phase, but it doesn't look like it is 
> pulling anything. No logs appear in the logs window.
> After around 5 minutes the build fails, and both stages print out
>
> process apparently never started in 
> /data1/jenkins_workingfolder/workspace/***/***@tmp/durable-9585b504 
> (running Jenkins temporarily with 
> -Dorg.jenkinsci.plugins.durabletask.BourneShellScript.LAUNCH_DIAGNOSTICS=true 
> might make the problem clearer)
>
> Unluckily this is a managed service an I'm unable to run jenkins with
> such an option activated. Anybody got an idea of what might be
> happening here?
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/91b0f91d-5c62-4fb8-967f-2bf44771bd44n%40googlegroups.com.


parallel jobs not starting with docker workflow

2020-07-24 Thread Marco Sacchetto
Hi,

I've been trying (with no result for now) to define a parallel declarative 
pipeline such as this:
```
pipeline{
agent any
stages {
stage('Configure projects') {
parallel {
stage('Configure 1') {
agent {
docker {
image ''
alwaysPull true
}
steps { . }
}
  stage('Configure 2') {
  
  }
   }
  }
...
```
I'm uncurring in an issue that is very similar to 
https://issues.jenkins-ci.org/browse/JENKINS-46831 , with the big question 
mark due that 
the bug there is from 2017 and our plugins are updated.
The build arrives up to the parallel closure, and it spins up the parallel
jobs in other available agents. At that point it gets stuck. On blueocean
it seems stuck at the docker pull phase, but it doesn't look like it is 
pulling anything. No logs appear in the logs window.
After around 5 minutes the build fails, and both stages print out

process apparently never started in 
/data1/jenkins_workingfolder/workspace/***/***@tmp/durable-9585b504 
(running Jenkins temporarily with 
-Dorg.jenkinsci.plugins.durabletask.BourneShellScript.LAUNCH_DIAGNOSTICS=true 
might make the problem clearer)

Unluckily this is a managed service an I'm unable to run jenkins with
such an option activated. Anybody got an idea of what might be
happening here?

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/8ace20d0-09b4-4125-9c69-0d201edf945bn%40googlegroups.com.


Re: Jenkins and HTTPS

2020-07-24 Thread Mark Waite
On Fri, Jul 24, 2020 at 9:12 AM Gianluca  wrote:

> Trying to guess:
>
> " java.net.SocketException: Permission denied"
>
> this smells of Java not running with enough privileges to open ports below
> 1024
> Usually on Linux systems only root can open such ports.
>
>
As further help with that, you might try the guidance for "Running Jenkins
behind iptables
"
.  That section of the reverse proxy configuration document uses the Linux
kernel's iptables facility to route traffic from the privileged port (80 or
443) to an unprivileged port (usually 8080).  The document is only recently
merged and we'd love to have feedback. corrections, and improvements to it.

Mark Waite


>
> On Friday, 24 July 2020 16:04:36 UTC+1, gaiseric.vandal wrote:
>>
>> I am setting up jenkins on an CentOS 8 machine.  Currently have one
>> running under Ubuntu 16.
>>
>>
>> On the new machine, I am unable to get HTTPS working, even tho the config
>> seems the same as the other machine.
>>
>>
>> My partial config file is
>>
>>
>>
>> # cat /etc/sysconfig/jenkins
>> #
>> JENKINS_HOME="/var/lib/jenkins"
>> JENKINS_JAVA_CMD=""
>> JENKINS_USER="jenkins"
>> #JENKINS_INSTALL_SKIP_CHOWN="false"
>> JENKINS_JAVA_OPTIONS="-Djava.awt.headless=true"
>> JENKINS_PORT="8080"
>> JENKINS_LISTEN_ADDRESS=""
>> JENKINS_HTTPS_PORT="443"
>> JENKINS_HTTPS_KEYSTORE="/etc/jenkins/jenkins.jks"
>> JENKINS_HTTPS_KEYSTORE_PASSWORD="xxx"
>> JENKINS_HTTPS_LISTEN_ADDRESS="0.0.0.0"
>> JENKINS_HTTP2_PORT=""
>> JENKINS_HTTP2_LISTEN_ADDRESS=""
>> JENKINS_DEBUG_LEVEL="5"
>> JENKINS_ENABLE_ACCESS_LOG="no"
>> JENKINS_HANDLER_MAX="100"
>>
>> JENKINS_HANDLER_IDLE="20"
>> JENKINS_EXTRA_LIB_FOLDER=""
>> JENKINS_ARGS=""
>> #
>>
>>
>>
>>
>> I am quite certain I have the key store correct
>>
>>
>> I set up with
>>
>> keytool -genkey -alias servername.mydomain.com   -keyalg RSA
>> -keystore /etc/jenkins/jenkins.jks -keysize 2048
>>
>> Then generated a CSR, had it signed by our internal CA.
>>
>> Also imported the certificates for the CA's.
>>
>>
>>
>>
>>
>> I have the following errors
>>
>>
>> $ cat /var/log/jenkins/jenkins.log
>>
>> Running from: /usr/lib/jenkins/jenkins.war
>>
>> Exception in thread "Jenkins initialization thread"
>> java.lang.NoClassDefFoundError: hudson/util/HudsonFailedToLoad
>>
>> at hudson.WebAppMain$3.run(WebAppMain.java:276)
>>
>> Caused by: java.lang.ClassNotFoundException:
>> hudson.util.HudsonFailedToLoad
>>
>> at java.net.URLClassLoader.findClass(Unknown Source)
>>
>>at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> at
>> org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:543)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 1 more
>>
>> java.io.IOException: Failed to start Jetty
>>
>> at winstone.Launcher.(Launcher.java:184)
>>
>> at winstone.Launcher.main(Launcher.java:355)
>>
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at Main._main(Main.java:375)
>>
>> at Main.main(Main.java:151)
>>
>> Caused by: java.net.SocketException: Permission denied
>>
>> at sun.nio.ch.Net.bind0(Native Method)
>>
>> at sun.nio.ch.Net.bind(Unknown Source)
>>
>> at sun.nio.ch.Net.bind(Unknown Source)
>>
>> at sun.nio.ch.ServerSocketChannelImpl.bind(Unknown
>> Source)
>>
>> at sun.nio.ch.ServerSocketAdaptor.bind(Unknown
>> Source)
>>
>> at
>> org.eclipse.jetty.server.ServerConnector.openAcceptChannel(ServerConnector.java:342)
>>
>> at
>> org.eclipse.jetty.server.ServerConnector.open(ServerConnector.java:307)
>>
>> at
>> org.eclipse.jetty.server.AbstractNetworkConnector.doStart(AbstractNetworkConnector.java:80)
>>
>> at
>> org.eclipse.jetty.server.ServerConnector.doStart(ServerConnector.java:231)
>>
>> at
>> org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72)

Re: [JCasC] can i utilize variables?

2020-07-24 Thread Mark Waite
In case it helps, here is an example that sets the Jenkins URL

based on an environment variable set from the script that launches it

.

On Fri, Jul 24, 2020 at 9:58 AM Ivan Fernandez Calvo <
kuisathave...@gmail.com> wrote:

> Hi,
>
> You can use environment variables inside of your JCasC file. If you need
> something more complicated you can use a Jinja template and
> https://github.com/kolypto/j2cli to make the transformation to YAML
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/a8d4e976-1d2d-4638-8ce3-69df6d86e9d6o%40googlegroups.com
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtG-UxXgG0NYpxqFSPa1y8GBgOV9qNFO8gm3J96U3RGz_g%40mail.gmail.com.


[JCasC] can i utilize variables?

2020-07-24 Thread Ivan Fernandez Calvo
Hi,

You can use environment variables inside of your JCasC file. If you need 
something more complicated you can use a Jinja template and 
https://github.com/kolypto/j2cli to make the transformation to YAML

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/a8d4e976-1d2d-4638-8ce3-69df6d86e9d6o%40googlegroups.com.


Re: Jenkins and HTTPS

2020-07-24 Thread Gianluca
Trying to guess:

" java.net.SocketException: Permission denied" 

this smells of Java not running with enough privileges to open ports below 
1024
Usually on Linux systems only root can open such ports.


On Friday, 24 July 2020 16:04:36 UTC+1, gaiseric.vandal wrote:
>
> I am setting up jenkins on an CentOS 8 machine.  Currently have one 
> running under Ubuntu 16.
>
>
> On the new machine, I am unable to get HTTPS working, even tho the config 
> seems the same as the other machine.
>
>
> My partial config file is 
>
>
>
> # cat /etc/sysconfig/jenkins
> #
> JENKINS_HOME="/var/lib/jenkins"
> JENKINS_JAVA_CMD=""
> JENKINS_USER="jenkins"
> #JENKINS_INSTALL_SKIP_CHOWN="false"
> JENKINS_JAVA_OPTIONS="-Djava.awt.headless=true"
> JENKINS_PORT="8080"
> JENKINS_LISTEN_ADDRESS=""
> JENKINS_HTTPS_PORT="443"
> JENKINS_HTTPS_KEYSTORE="/etc/jenkins/jenkins.jks"
> JENKINS_HTTPS_KEYSTORE_PASSWORD="xxx"
> JENKINS_HTTPS_LISTEN_ADDRESS="0.0.0.0"
> JENKINS_HTTP2_PORT=""
> JENKINS_HTTP2_LISTEN_ADDRESS=""
> JENKINS_DEBUG_LEVEL="5"
> JENKINS_ENABLE_ACCESS_LOG="no"
> JENKINS_HANDLER_MAX="100"
>
> JENKINS_HANDLER_IDLE="20"
> JENKINS_EXTRA_LIB_FOLDER=""
> JENKINS_ARGS=""
> #
>
>
>
>
> I am quite certain I have the key store correct
>
>
> I set up with 
>
> keytool -genkey -alias servername.mydomain.com   -keyalg RSA 
> -keystore /etc/jenkins/jenkins.jks -keysize 2048
>
> Then generated a CSR, had it signed by our internal CA.
>
> Also imported the certificates for the CA's.
>
>
>
>
>
> I have the following errors
>
>
> $ cat /var/log/jenkins/jenkins.log
>
> Running from: /usr/lib/jenkins/jenkins.war
>
> Exception in thread "Jenkins initialization thread" 
> java.lang.NoClassDefFoundError: hudson/util/HudsonFailedToLoad
>
> at hudson.WebAppMain$3.run(WebAppMain.java:276)
>
> Caused by: java.lang.ClassNotFoundException: 
> hudson.util.HudsonFailedToLoad
>
> at java.net.URLClassLoader.findClass(Unknown Source)
>
>at java.lang.ClassLoader.loadClass(Unknown Source)
>
> at java.lang.ClassLoader.loadClass(Unknown Source)
>
> at 
> org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:543)
>
> at java.lang.ClassLoader.loadClass(Unknown Source)
>
> ... 1 more
>
> java.io.IOException: Failed to start Jetty
>
> at winstone.Launcher.(Launcher.java:184)
>
> at winstone.Launcher.main(Launcher.java:355)
>
> at 
> sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>
> at 
> sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>
> at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>
> at java.lang.reflect.Method.invoke(Unknown Source)
>
> at Main._main(Main.java:375)
>
> at Main.main(Main.java:151)
>
> Caused by: java.net.SocketException: Permission denied
>
> at sun.nio.ch.Net.bind0(Native Method)
>
> at sun.nio.ch.Net.bind(Unknown Source)
>
> at sun.nio.ch.Net.bind(Unknown Source)
>
> at sun.nio.ch.ServerSocketChannelImpl.bind(Unknown 
> Source)
>
> at sun.nio.ch.ServerSocketAdaptor.bind(Unknown Source)
>
> at 
> org.eclipse.jetty.server.ServerConnector.openAcceptChannel(ServerConnector.java:342)
>
> at 
> org.eclipse.jetty.server.ServerConnector.open(ServerConnector.java:307)
>
> at 
> org.eclipse.jetty.server.AbstractNetworkConnector.doStart(AbstractNetworkConnector.java:80)
>
> at 
> org.eclipse.jetty.server.ServerConnector.doStart(ServerConnector.java:231)
>
> at 
> org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72)
>
> at 
> org.eclipse.jetty.server.Server.doStart(Server.java:385)
>
> at 
> org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72)
>
> at winstone.Launcher.(Launcher.java:182)
>
> ... 7 more
>
> $
>
>
>
> I also tried extracting the key and cert  and tried the following
>
>  /etc/alternatives/java -Dcom.sun.akuma.Daemon=daemonized 
> -Djava.awt.headless=true -DJENKINS_HOME=/var/lib/jenkins -jar 
> /usr/lib/jenkins/jenkins.war --logfile=/var/log/jenkins/jenkins.log 
> --webroot=/var/cache/jenkins/war --daemon --httpPort=8080 --httpsPort=443   
> --httpsListenAddress=0.0.0.0 --debug=5 --handlerCountMax=100 
> 

Jenkins and HTTPS

2020-07-24 Thread Gaiseric Vandal
I am setting up jenkins on an CentOS 8 machine.  Currently have one 
running under Ubuntu 16.



On the new machine, I am unable to get HTTPS working, even tho the 
config seems the same as the other machine.



My partial config file is



# cat /etc/sysconfig/jenkins
#
JENKINS_HOME="/var/lib/jenkins"
JENKINS_JAVA_CMD=""
JENKINS_USER="jenkins"
#JENKINS_INSTALL_SKIP_CHOWN="false"
JENKINS_JAVA_OPTIONS="-Djava.awt.headless=true"
JENKINS_PORT="8080"
JENKINS_LISTEN_ADDRESS=""
JENKINS_HTTPS_PORT="443"
JENKINS_HTTPS_KEYSTORE="/etc/jenkins/jenkins.jks"
JENKINS_HTTPS_KEYSTORE_PASSWORD="xxx"
JENKINS_HTTPS_LISTEN_ADDRESS="0.0.0.0"
JENKINS_HTTP2_PORT=""
JENKINS_HTTP2_LISTEN_ADDRESS=""
JENKINS_DEBUG_LEVEL="5"
JENKINS_ENABLE_ACCESS_LOG="no"
JENKINS_HANDLER_MAX="100"

JENKINS_HANDLER_IDLE="20"
JENKINS_EXTRA_LIB_FOLDER=""
JENKINS_ARGS=""
#




I am quite certain I have the key store correct


I set up with

    keytool -genkey -alias servername.mydomain.com   -keyalg RSA 
-keystore /etc/jenkins/jenkins.jks -keysize 2048



Then generated a CSR, had it signed by our internal CA.

Also imported the certificates for the CA's.





I have the following errors


            $ cat /var/log/jenkins/jenkins.log

Running from: /usr/lib/jenkins/jenkins.war

Exception in thread "Jenkins initialization thread" 
java.lang.NoClassDefFoundError: hudson/util/HudsonFailedToLoad


at hudson.WebAppMain$3.run(WebAppMain.java:276)

Caused by: java.lang.ClassNotFoundException: hudson.util.HudsonFailedToLoad

at java.net.URLClassLoader.findClass(Unknown Source)

at java.lang.ClassLoader.loadClass(Unknown Source)

at java.lang.ClassLoader.loadClass(Unknown Source)

at 
org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:543)


at java.lang.ClassLoader.loadClass(Unknown Source)

... 1 more

java.io.IOException: Failed to start Jetty

at winstone.Launcher.(Launcher.java:184)

at winstone.Launcher.main(Launcher.java:355)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

at java.lang.reflect.Method.invoke(Unknown Source)

at Main._main(Main.java:375)

at Main.main(Main.java:151)

Caused by: java.net.SocketException: Permission denied

at sun.nio.ch.Net.bind0(Native Method)

at sun.nio.ch.Net.bind(Unknown Source)

at sun.nio.ch.Net.bind(Unknown Source)

at sun.nio.ch.ServerSocketChannelImpl.bind(Unknown Source)

at sun.nio.ch.ServerSocketAdaptor.bind(Unknown Source)

at 
org.eclipse.jetty.server.ServerConnector.openAcceptChannel(ServerConnector.java:342)


at org.eclipse.jetty.server.ServerConnector.open(ServerConnector.java:307)

at 
org.eclipse.jetty.server.AbstractNetworkConnector.doStart(AbstractNetworkConnector.java:80)


at 
org.eclipse.jetty.server.ServerConnector.doStart(ServerConnector.java:231)


at 
org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72)


at org.eclipse.jetty.server.Server.doStart(Server.java:385)

at 
org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72)


at winstone.Launcher.(Launcher.java:182)

... 7 more

$



I also tried extracting the key and cert and tried the following

 /etc/alternatives/java -Dcom.sun.akuma.Daemon=daemonized 
-Djava.awt.headless=true -DJENKINS_HOME=/var/lib/jenkins -jar 
/usr/lib/jenkins/jenkins.war --logfile=/var/log/jenkins/jenkins.log 
--webroot=/var/cache/jenkins/war --daemon --httpPort=8080 
--httpsPort=443   --httpsListenAddress=0.0.0.0 --debug=5 
--handlerCountMax=100 --handlerCountMaxIdle=20 
--httpsCertificate=/etc/jenkins/jenkins.cer 
--httpsPrivateKey=/etc/jenkins/jenkins.key




Same errors.


I disabled selinux.  Did not help.


Tried linking /etc/alternative/java (default in the search path ) to 
Oracle 8 Java, OpenJDK8 and OpenJDK11.  No luck.




Appreciate any advice.


Thanks




--
You received this message because you are subscribed to the Google Groups "Jenkins 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/f80452f4-d3c7-6928-efb2-20e618e329f7%40gmail.com.


Re: Robot Framework test run from Jenkins. - No module named robot

2020-07-24 Thread Slide
My guess is that Jenkins (either the agent or server) is running as a
different user, so the module isn't installed for that user. You show
"robert.szabo" for where robot.exe is installed, but is that the user that
Jenkins is running as on that system?

On Fri, Jul 24, 2020 at 6:48 AM Eric Pyle  wrote:

> I wonder if this is because AppData is a hidden folder, and/or not
> accessible to the user running Jenkins. Can you try a directory listing of
> that Scripts directory in a Jenkins job batch command?
>
> Eric
>
> On 7/22/2020 11:50 AM, Robert Szabo wrote:
>
> Hi,
>
> Jenkins cant run my Robot Framework test cases.
>
> I run this job in Execute Windows batch command
>
> cd C:\work\robot\Es1P\
> set
> PYTHONPATH=C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts
> echo %PYTHONPATH%
> python.exe -m robot C:\work\robot\Es1P
> echo Completed
>
>
> Jenkins run of it always fails, console output is this:
>
> -
> Console Output
>
> Started by user admin 
> Running as SYSTEM
> Building in workspace C:\Program Files (x86)\Jenkins\workspace\r1
> [r1] $ cmd /c call C:\windows\TEMP\jenkins1877465942945470142.bat
>
> C:\Program Files (x86)\Jenkins\workspace\r1>cd C:\work\robot\Es1P\
>
> C:\work\robot\Es1P>set 
> PYTHONPATH=C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts
>
> C:\work\robot\Es1P>echo 
> C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts
> C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts
>
> C:\work\robot\Es1P>python.exe -m robot C:\work\robot\Es1P
> C:\Program Files\Python37\python.exe: No module named robot
>
> C:\work\robot\Es1P>echo Completed
> Completed
>
> C:\work\robot\Es1P>exit 1
> Build step 'Execute Windows batch command' marked build as failure
> Finished: FAILURE
>
> -
>
> checking robot location in Powershell
>
>  (get-command robot.exe).Path
>
>  PS C:\work\robot\Es1P> (get-command robot.exe).Path
> C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts\robot.exe
>
>  So i think PYTHONPATH should work, but seems not.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/63d9fc16-cdd1-4db1-bb3e-cbb5908ddb83o%40googlegroups.com
> 
> .
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/986c8bfa-07c4-7660-9d7f-db553d713d90%40cd-adapco.com
> 
> .
>


-- 
Website: http://earl-of-code.com

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAPiUgVdDZ6jAbwcLettKM2Seo6PZZ0wqyfShUkFVeDOO9MmGjw%40mail.gmail.com.


Re: Robot Framework test run from Jenkins. - No module named robot

2020-07-24 Thread Eric Pyle
I wonder if this is because AppData is a hidden folder, and/or not 
accessible to the user running Jenkins. Can you try a directory listing 
of that Scripts directory in a Jenkins job batch command?


Eric

On 7/22/2020 11:50 AM, Robert Szabo wrote:

Hi,

Jenkins cant run my Robot Framework test cases.

I run this job in Execute Windows batch command

cd C:\work\robot\Es1P\
set 
PYTHONPATH=C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts

echo %PYTHONPATH%
python.exe -m robot C:\work\robot\Es1P
echo Completed


Jenkins run of it always fails, console output is this:

-
Console Output
Started by useradmin  
Running as SYSTEM
Building in workspace C:\Program Files (x86)\Jenkins\workspace\r1
[r1] $ cmd /c call C:\windows\TEMP\jenkins1877465942945470142.bat

C:\Program Files (x86)\Jenkins\workspace\r1>cd C:\work\robot\Es1P\

C:\work\robot\Es1P>set 
PYTHONPATH=C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts

C:\work\robot\Es1P>echo 
C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts
C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts

C:\work\robot\Es1P>python.exe -m robot C:\work\robot\Es1P
C:\Program Files\Python37\python.exe: No module named robot

C:\work\robot\Es1P>echo Completed
Completed

C:\work\robot\Es1P>exit 1
Build step 'Execute Windows batch command' marked build as failure
Finished: FAILURE
-
checking robot location in Powershell
(get-command robot.exe).Path
PS C:\work\robot\Es1P> (get-command robot.exe).Path 
C:\Users\robert.szabo\AppData\Roaming\Python\Python37\Scripts\robot.exe

So i think PYTHONPATH should work, but seems not.
--
You received this message because you are subscribed to the Google 
Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send 
an email to jenkinsci-users+unsubscr...@googlegroups.com 
.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/63d9fc16-cdd1-4db1-bb3e-cbb5908ddb83o%40googlegroups.com 
.


--
You received this message because you are subscribed to the Google Groups "Jenkins 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/986c8bfa-07c4-7660-9d7f-db553d713d90%40cd-adapco.com.


Issue accesing variable inside script in ActiveChoice plugin (ver2.4)

2020-07-24 Thread chencho m-a
Hi all, 

I have a script which is writting the configuration of ActiveChoice instead 
of use the browser. 

So I am sending a hashmap as parameters but I am unable to acces it inside 
the script 

def components_param(hash_map){ // Section header
return [$class: 'DynamicReferenceParameter',
choiceType: 'ET_FORMATTED_HTML', 
description: '', 
name: '', 
randomName: "choice-parameter-${UUID.randomUUID()}",
omitValueField: false,
referencedParameters: 'sdk',
script: [
$class: 'GroovyScript',
fallbackScript: [
classpath: [], sandbox: false, script: 'return 
["Error,can\'t retrieve components"]',
],
script: [
classpath: [], sandbox: false, script:'''
def output="Components to be updated ${sdk}"
for (comp in  '''+hash_map+'''[sdk].keySet()) {
output += ""+comp+""
}

output+=""
return output
'''
]
]   
]
}

If I check the content in jenkins UI, i got this error:

startup failed:
Script1: 3: illegal colon after argument expression;
   solution: a complex label expression before a colon must be 
parenthesized @ line 3, column 43.

The hash_map in jenkins UI takes this form:

 [devel:[extensions:[extension1:[data:[name:name1, type:generic], 
sdk-ext:sdk-ext-extension1-devel,  extension1-release: 
extension1-sdk-1.21.0.0-devel, ...

How can I parse this hashmap inside ActiveChoice script? In any groovy 
console is something like:

sdks=hash_map.keySet()
sdk=sdks[1]
for (comp in hash_map[sdk].keySet()) {
println comp
}

Any help will be appreciated

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/f8746735-501c-4a9e-91b3-3a423eb3125fn%40googlegroups.com.


Re: [JCasC] can i utilize variables?

2020-07-24 Thread nigel.a...@braincorp.com
I don't believe JCasC support variables in the yaml, but in our project we 
use jsonnet  to be able to template or use variables 
in the creation of the casc.

-Nigel

On Thursday, July 23, 2020 at 1:59:41 PM UTC-7 j wrote:

> Hi!
>
> I am new to this.  I have been trying to figure out a way to utilize 
> variables in the yaml file.
>
> Help.
>
> Regards,
> J
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/c96ca6ba-89e6-4ea9-b5ce-05313ba4a208n%40googlegroups.com.


Re: Help needed with setting up credentials for Bitbucket-branch-source-plugin

2020-07-24 Thread Richard Bywater
For use with a multibranch type job you'll need username & password/token
credentials for a Bitbucket user which has read access to the repo (or
admin access if you want Jenkins to setup the hooks automatically).
For use with an organisation folder type job (with Bitbucket server at
least - haven't used Bitbucket cloud so can't fully comment) you'll want a
username & password/token credentials for a Bitbucket user which has read
access to a project (or admin access if you want Jenkins to setup the hooks
automatically).

If that's not working then you'll need to be a bit clearer about the error
that you are getting as it could be a number of things.

Richard.

On Fri, 24 Jul 2020 at 04:56, Ashish Sharma  wrote:

> Dear community,
>
> I need help in understanding how setting up credentials work for this
> plugin.
>
> Does this require system admin level username / password or any user
> credentials (who has read access on repo) can be provided.
>
> Also any limitations on what kind of directory that user is coming from?
> We are using delegated ldap for microsoft active directory in bitbucket.
>
> I tried to setup using a general user credentials but its not able to
> fetch repositories with project name, it keeps showing error message. Does
> this have to be the project admin user credentials?
>
> Thanks,
> Ashish
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/1fe9539e-3ee3-4e49-86d0-dfda77f3fca2o%40googlegroups.com
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAAy0hwc84N4YeCKiTO39zPDNRCdCXRpfqrjbiQxeWYPdkkCtYg%40mail.gmail.com.