Re: Jenkins Kuberenet Plugin

2020-10-07 Thread David Foley
Am I correct that pipelines are only supported and not Freestyle? I created a Test Pipeline, and am able to see the ansible version when I ran "sh 'ansible --version'" so it appears the freestyle is using the JNLP container. On Wed, 7 Oct 2020 at 21:24, David Foley wrote: > Hi Nigel > > I'm

Re: Jenkins Kuberenet Plugin

2020-10-07 Thread David Foley
Hi Nigel I'm using FreeStyle Project. I have selected restricted to run on Node: Ansible On Wed, 7 Oct 2020 at 20:42, Nigel Armstrong wrote: > David, > > It sounds like you might not be running the step inside the > right container. By default steps are runin the jnlp container. You need to >

Re: Jenkins Kuberenet Plugin

2020-10-07 Thread Nigel Armstrong
David, It sounds like you might not be running the step inside the right container. By default steps are runin the jnlp container. You need to specify `container('container-name') {` for which container to run in. See the documentation: https://plugins.jenkins.io/kubernetes/ -Nigel On Wed, Oct

How to get failed stage name during parallel run of stages?

2020-10-07 Thread Gajanan Mahajan
I've a pipeline where multiple stages run in parallel but if any of the stages fails, I want to get its name to show failed stage. With following code, even if it fails in first stage ie `Checking Redmine access`, it always show last stage as failed i.e. `Checking Reviewers list`. This is

Run jenkins jobs as different user or switch user during the execution

2020-10-07 Thread Amit Chettri
Hello, I have a requirement where I need to switch user in between in the pipeline run : : steps { script { sh """ sudo su - testuser whoami """ : : : } } but during the pipeline run user is not

Re: Jenkins Kuberenet Plugin

2020-10-07 Thread David Foley
When jenkins deploys the pod jnlp container along with my ansible container is created within that Pod, My docker file is using Ubuntu should I be using the jenkins/jnlp image instead. If I keep the pod after the jobs fails and execute shell a d run which ansible is shows the path On Wed 7 Oct

Re: Jenkins Kuberenet Plugin

2020-10-07 Thread nigel.a...@braincorp.com
David, Looks like your issue isn't with the dockerfile, but with ansible. The failure is listed as `ansible: not found`. Make sure your executor has ansible and its in the path. Note the user and directory jenkins is running the command in. -Nigel On Wednesday, October 7, 2020 at 4:09:38 AM

Declarative Pipeline to trigger Job in Post-build actions if condition satisfies

2020-10-07 Thread john levin
Hello Team, Shall we put a if condition in post build actions to trigger other jobs if condition matches. Say for example If date matches Wednesday, trigger the other job in post build actions. /John -- You received this message because you are subscribed to the Google Groups "Jenkins