title: Passing the output of a job in Jenkins to another job
body: <p>I made quite the research on this but couldn't find a satisfying answer. The following process will be automatic, repeating every night so no parameters could be passed in manually by the user at runtime. Parent job calls all the following subprocesses in a blocking chain My job hierarchy is set up like this with following main jobs and subprocesses:</p>
  
  <p>Run-Tests-EveryNight (Parent Job)--> Create-A-Virtual-Machiene --> Run-Tests-On-VM</p>
  
  <p>Moving on, when you create a VM it gets assigned a generated IP address, I need to pass in that IP address to Run-Tests-On-VM as a parameter but I can not seem to find any way to do it.</p>
  
  <p>Clarification: Some people found the question unclear so: I am asking how to pass in the dynamically created IP address of a Virtual Machine as a PARAMETER to a different job (a subprocess) </p>
  
  <p>NOTE: I have read about copying artifacts but I feel like it doesnt work in this case (plus writing and then reading from a file is way too much work for a simple parameter passing.)</p>
  
  <p>I feel like there should be a really easy way to do this...  </p>
  
  <p><strong>UPDATE:</strong> The use of Parameterized Trigger Plugin was suggested. I am already using and have the following bash script to copy the properties </p>
  
  <pre><code># Create override properties file for functional tests
  FILENAME="user.properties"
  cd "path of the file goes here"
  rm -f $FILENAME
  echo "FQDN=$VM_FQDN" &gt;&gt; $FILENAME
  </code></pre>
  
  <p>However I do not know how to write into this file (or create a new properties file, to save the IP address as a post-build action</p>
  
  <p><strong>Answer:</strong> Following the answer below, use either of these threads to modify the properties file or use inject option in Jenkins
  <a href="https://stackoverflow.com/questions/5821545/archive-the-artifacts-in-hudson-jenkins">Archive the artifacts in hudson/jenkins</a></p>
  
  <p><a href="https://stackoverflow.com/questions/3868310/how-can-i-change-a-properties-file-in-maven-depending-on-my-profile">How can I change a .properties file in maven depending on my profile?</a></p>
  
  <p>Thanks</p>