Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-68776

Bash Script Fails During Jenkins Build But Does Not Fail Locally

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not A Defect
    • Icon: Blocker Blocker
    • pipeline
    • None
    • Jenkins build that executes on a Linux CentOS7 VM

      I've been trying to debug this issue all day with no success.

      Issue: Bash script executes successfully on a Linux CentOS7 VM (jenkins build agent) but fails during Jenkins build.

      Here's the simple script.

      #! /bin/bash 
      
      echo "before beyond compare command" 
      
      bcompare @"bc_report.ps1" "./Output_Base/<Folder_Name>" "./Output_Compare/<Folder Name>" "Report.html" 
      
      echo "after beyond compare command"  

      The output in the Jenkins build log is just:

      before beyond compare command 
      after beyond compare command  

      When viewing the VM during the Jenkins build, I'm not seeing an artifact being produced. The user during the Jenkins build is Root, when executing the script locally, I'm also doing so as Root with success.

      I suppose technically the script isn't failing but it's not executing the bcompare command.

      I'm pretty sure this is a Jenkins issue, just can't seem to figure it out. Anyone seen something similar?

            Unassigned Unassigned
            uncowandy Randy York
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: