code: void installPuppetModules( Instance instance )
  	throws IOException, InterruptedException {
  
  		// Load the modules names
  		File instanceDirectory = InstanceHelpers.findInstanceDirectoryOnAgent( instance );
  		File modulesFile = new File( instanceDirectory, "modules.properties" );
  		if( ! modulesFile.exists())
  			return;
  
  		Properties props = Utils.readPropertiesFile( modulesFile );
  		for( Map.Entry<Object,Object> entry : props.entrySet()) {
  
  			List<String> commands = new ArrayList<> ();
  			commands.add( "puppet" );
  			commands.add( "module" );
  			commands.add( "install" );
  
  			String value = entry.getValue().toString();
  			if( ! Utils.isEmptyOrWhitespaces( value )) {
  				commands.add( "--version" );
  				commands.add( value );
  			}
  
  			commands.add((String) entry.getKey());
  			commands.add( "--target-dir" );
  			commands.add( instanceDirectory.getAbsolutePath());
  
  			String[] params = commands.toArray( new String[ 0 ]);
  			this.logger.fine( "Module installation: " + Arrays.toString( params ));
  
  			int exitCode = ProgramUtils.executeCommand( this.logger, commands, null, null, this.applicationName, this.scopedInstancePath);
  			if( exitCode != 0 )
  				throw new IOException( "Puppet modules could not be installed for " + instance + "." );
  		}
  	}
docs: Executes a Puppet command to install the required modules.
  @param instance the instance
  @throws IOException
  @throws InterruptedException
  @throws PluginException