Uploaded image for project: 'Bamboo Data Center'
  1. Bamboo Data Center
  2. BAM-1986

Variable substitution should not assume that the result will be contained within a single command argument

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Medium Medium
    • 2.1.5
    • 1.2.4
    • Tasks
    • None

      Bamboo has undocumented restrictions with how you can use global variable substitution for a plan's goal. In our case, we have a batch of plans that all share the same set of verbose configuration options.

      I defined a global variable, OPT.DBSETTINGS to represent a series of options that are common to several builds. This looks something like:

      -Ddb.host=our.db.server -Ddb.port=5001 -Ddb.dbname=xe

      It's a fair bit longer than that, but you get the idea. I passed this as a goal to our maven 1 builder like this:

      Goal: ${bamboo.OPT.DBSETTINGS} full

      This doesn't get passed to maven in the way I'd hoped. Instead of:

      Property Value
      db.host our.db.server
      db.port 5001
      db.dbname xe

      ..maven receives:

      Property Value
      db.host our.db.server -Ddb.port=5001 -Ddb.dbname=xe
      db.port not set
      db.dbname not set

      Other global variables of the form -Dpropertyname=value get through as expected.

            kbrazulewicz Krystian Brazulewicz
            9bd070aa0ec1 Michael Prescott
            Votes:
            2 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 4h Original Estimate - 4h
                4h
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 8h
                8h