Uploaded image for project: 'Beaker'
  1. Beaker
  2. BKR-7

beaker's prebuild_steps corrupts PATH on windows+cygwin

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Template:

      Error rendering 'issue-templates-customfield'. Please contact your Jira administrators.

    • Story Points:
      3
    • Sprint:
      QE 2015-03-25

      Description

      When beaker provisions a Windows host, it uses host['pathseparator'] to write PATH to ~/.ssh/environment. This was changed in commit https://github.com/puppetlabs/beaker/blame/master/lib/beaker/host_prebuilt_steps.rb#L476.

      As a result, the PATH is as follows (note the semicolon):

      $ ssh -i ~/.ssh/jenkins Administrator@cyn9u9rv9zzrel8.delivery.puppetlabs.net 'echo $PATH'
      /cygdrive/c/Program Files (x86)/Puppet Labs/Puppet/bin:/cygdrive/c/Program Files/Puppet Labs/Puppet/bin;/opt/puppet-git-repos/hiera/bin:/cygdrive/c/Windows/system32:/cygdrive/c/Windows:/cygdrive/c/Windows/System32/Wbem:/cygdrive/c/Windows/System32/WindowsPowerShell/v1.0:/cygdrive/c/pstools:/bin
      

      This is unfortunately the wrong thing to do when using cygwin, because it treats PATH specially, different from other environment variables.

      The code path needs to be modified so that if it's windows and cygwin and the environment variable is PATH, then it needs to use ':' as the separator. For other environment variables like RUBYLIB it should continue using the host['pathseparator']

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              alice Alice Nodelman
              Reporter:
              josh Josh Cooper
              Votes:
              2 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Zendesk Support