• Icon: Bug Bug
    • Resolution: Fixed
    • Icon: High High
    • 5.6.0
    • 5.3
    • Tasks, Variables
    • None

      I have a script in /var/tmp that simply executes "env" – the output of which follows:

      16-Jan-2014 18:29:35 Starting task 'Print Env' of type 'com.atlassian.bamboo.plugins.scripttask:task.builder.script'
      16-Jan-2014 18:29:35
      Beginning to execute external process for build 'XXXX #5 (XXXX-5)'
      ... running command line:
      /bin/sh /var/tmp/env.sh
      ... in: /opt/atlassian/bamboo/current/xml-data/build-dir/XXXX
      16-Jan-2014 18:29:35 TERM=xterm
      16-Jan-2014 18:29:35 JAVA_OPTS=-XX:MaxPermSize=256m -Xms256m -Xmx384m
      16-Jan-2014 18:29:35 LD_LIBRARY_PATH=/usr/java/jdk1.6.0_27/jre/lib/amd64/server:/usr/java/jdk1.6.0_27/jre/lib/amd64:/usr/java/jdk1.6.0_27/jre/../lib/amd64
      16-Jan-2014 18:29:35 NLSPATH=/usr/dt/lib/nls/msg/%L/%N.cat
      16-Jan-2014 18:29:35 PATH=/sbin:/usr/sbin:/bin:/usr/bin
      16-Jan-2014 18:29:35 _=/bin/env
      16-Jan-2014 18:29:35 PWD=/opt/atlassian/bamboo/atlassian-bamboo-5.3/xml-data/build-dir/XXXX
      16-Jan-2014 18:29:35 JAVA_HOME=/usr/java/latest
      16-Jan-2014 18:29:35 JAVA_PERMGEN_SUPPORTED=true
      16-Jan-2014 18:29:35 XFILESEARCHPATH=/usr/dt/app-defaults/%L/Dt
      16-Jan-2014 18:29:35 SHLVL=4
      16-Jan-2014 18:29:35 Finished task 'Print Env'

      As you can plainly see, the variables are nowhere in there.

      I see people complaining about these variables not being populated all the way back to the 4.x series. What's going on?

            [BAM-14218] File Scripts do not expose Build variables

            This will be added to Bamboo 5.6

            Marcin Gardias added a comment - This will be added to Bamboo 5.6

            Is there any update on this? File scripts are quite useless with this bug. This is critical since January.

            The whole reason I'm using scripts is due to this limitation: BAM-14027.
            Now, I have parallelised jobs that involve the same steps, an ability encouraged through Bamboo documentation. They involve similar scripts, I now must maintain them all inline rather than utilise a common script?...
            I feel like I bounce from bug to limitation and back again with Bamboo currently .
            If a workaround involves defining all necessary Bamboo provided environment variables in each task, I might as well copy and paste inline scripts everywhere.

            Louis Burton added a comment - Is there any update on this? File scripts are quite useless with this bug. This is critical since January. The whole reason I'm using scripts is due to this limitation: BAM-14027 . Now, I have parallelised jobs that involve the same steps, an ability encouraged through Bamboo documentation. They involve similar scripts, I now must maintain them all inline rather than utilise a common script?... I feel like I bounce from bug to limitation and back again with Bamboo currently . If a workaround involves defining all necessary Bamboo provided environment variables in each task, I might as well copy and paste inline scripts everywhere.

            Nevermind, we found a work around.

            Thomas Lockney added a comment - Nevermind, we found a work around.

            Is there any update on this issue? It's a rather major blocker for us.

            Thomas Lockney added a comment - Is there any update on this issue? It's a rather major blocker for us.

              mgardias Marcin Gardias
              3789d183d9b6 dustin_barnes
              Affected customers:
              6 This affects my team
              Watchers:
              8 Start watching this issue

                Created:
                Updated:
                Resolved: