RUSH RENDER QUEUE - ENVIRONMENT VARIABLES
(C) Copyright 1995,2000 Greg Ercolano. All rights reserved.
V 102.42 12/19/04


Environment Variables

    These environment variables are used by the rush system. Some variables affect the behavior of the rush client program, and some are set by the rush daemon to pass information to the user's Render Script. Some fall into both categories.

    Render Scripts should at very least make use of $RUSH_FRAME or $RUSH_PADFRAME to determine the current frame being rendered.







  RUSH_DIR  

    RUSH_DIR is an environment variable used by rush(1), and many of the various rush programs to determine where rush is installed. It is also passed to the render script.

    This variable is the directory name of the rush directory. Normally, this is /usr/local/rush. Appending '/bin' gives a path to the rush(1) and rushd(8) binaries.

    This variable should be in the user's environment so all rush(1) commands can access it, and as well, should also be set in the boot scripts before rushd(8) is started. Both rush(1) and rushd(8) depend on this variable being set.

  RUSH_FRAME  

    RUSH_FRAME is an environment variable passed to the render script.

    It contains the frame number to be rendered, i.e., "1", "12", "104". No padded zeroes are used.

  RUSH_FU  

    RUSH_FU is an environment variable used by the rush(1) command.

    If set to '1', implies the '-fu' flag for all commands. Not recommended for use in user's environment. This variable is meant only to be used by GUI interfaces that are layered on top of the rush command line tool.

  RUSH_HOSTNAME  

    RUSH_HOSTNAME is an environment variable passed to the render script.

    It contains the hostname the render script is currently running on. This is the name that appears in 'rush -lah' reports, and in the 'HOSTNAME' column of 'rush -lf' reports.

  RUSH_JOBID  

    RUSH_PADFRAME is an environment variable interpreted by the rush(1) command, and is also passed to the render script.

    It contains the jobid of the current running job. i.e., "tahoe-37"

    When this variable is set, the rush(1) command line tool will use this jobid if no jobid is specified.

    Example: 'rush -lf' will use RUSH_JOBID to determine which job's framelist to display, whereas specifying a jobid with eg. 'rush -lf tahoe.37' overrides the RUSH_JOBID setting.

    Since RUSH_JOBID is passed to the render script, rush(1) commands can be added to the render script without specifying the jobid, as it will be set already. eg. to reset the try count of the current frame from within the render script, only 'rush -try 0' is needed; there is no need to specify 'rush -try 0 $RUSH_JOBID'.

  RUSH_LOGFILE  

    RUSH_LOGFILE is an environment variable passed to the render script.

    It contains the absolute path to the output log for the currently running render script. The contents of this file grows as the render script generates output.

    The pathname in this variable always ends with the frame number being rendered [eg. 0001, 0002, 0003], so it will be a pathname specific to the current frame being rendered.

    This variable is dependent on the job's current LogDir value, which can be changed dynamically with the rush -logdir command line option.

    For example, the render script can use this variable to search the renderer's output for error messages, and act conditionally based on the error detected. See Detecting Render Problems with Grep for examples of this technique.

  RUSH_PADFRAME  

    RUSH_PADFRAME is an environment variable passed to the render script.

    It contains the frame number to be rendered, and includes 4 padding zeroes,
    I.e., "0001", "0012", "0104".

  RUSH_RAM  

    RUSH_RAM is an environment variable passed to the render script.

    It contains the job's current Ram value, which can be changed dynamically with the rush -ram command line option.

  RUSH_TMPDIR  
    RUSH_TMPDIR is an environment variable passed to the render script.

    It contains the path to a temp directory that is automatically created before the frame starts rendering, and is completely removed after the frame completes execution, deleting all files left behind.

    This variable is dependent on the current TmpDir setting in the rush.conf file.

    Use this variable when creating temporary files in your render script, so that the files are automatically removed even if your renders are bumped or dumped while in progress, e.g.,

      Using RUSH_TMPDIR
      
          ### YOUR RENDER COMMANDS HERE
          render -output $RUSH_TMPDIR/foo.rgb
          post_filter -in=$RUSH_TMPDIR/foo.rgb \
      		-out=/job/SHOW/img/$RUSH_PADFRAME.rgb             
      	
              

  RUSH_TRY  

    RUSH_TRY is an environment variable passed to the render script.

    It contains a value indicating the number of times this frame has attempted to render the frame (changed from Run -> Que). This is the number in the 'TRY' column of a 'rush -lf' report.

    Can be changed with rush -try.