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

Inject environment variables with property file not working

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • envinject-plugin
    • None
    • Jenkins ver. 1.421
      Windows XP Prof. (SP3)

      • Using the Build Step: "Inject environment variables"
        with following parameters:
        "Properties File Path:" E:\test\my_env.properties
        "Properties Content:" LIBS_ALL=x
      • Checking result with: "Execute Windows batch command"
        Command: set

      Result:

      • Correct setting of environment variables set with "Properties Content" (e.g. LIBS_ALL)
      • No environment variables set by using "Properties File Path"

      Relating Console output:
      ...
      [EnvInject] - Injecting as environment variables the properties file path 'E: / test / my_env.properties'
      [EnvInject] - Injecting as environment variables the properties content
      'LIBS_ALL=x'

      ...
      ...\workspace>set
      ...
      LIBS_ALL=x
      ...

      Note:
      Please consider the spaces in the path of the console output ('E: / test / my_env.properties')!

      The same "my_env.properties" file was tested using "Jenkins Environment File Plugin"

      • Build Triggers: Set environment variables through a file
        -> Using the "Jenkins Environment File Plugin", the environment variables are set correctly!

            gbois Gregory Boissinot
            nify Nico Falk
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: