Specify options in an file
Specify Pax Runner options in a text file
If you want to provide Pax Runner in a text file instead of command line you can use the --args option and specify the URL of a text file that contains the options.
pax-run --args=<URL>
By default (if --args is not specified) Pax Runner will look for and use, if available, a file named runner.args from the current directory. If your do not need this behavior you can ops4j:disable it.
If extra options / arguments are present in the command line beside the --args option then the command line options will have precedence.
Options file syntax
Options file must be a text file that contains one option per line. Beside the options the file can contain empty lines as well as commentary lines. Commentary lines are considered lines that start with # and those lines are skipped.
Here is an example:
runner.args
#Using Felix as a platform
--platform=felix
#Using version 1.4.0 of Felix
--version=1.4.1
Starting with release 0.20.0 of Pax Runner, you can specify the option values split over multiple lines, provided that the line ends with a "\". The next line will be appended to the previous line unless the next line is a blank line.
--vmo=-Doscar.embedded.execution=false\
-Djava.library.path=native\
# VM option to specify loggin configuration file
-Djava.util.logging.config.file=../conf/logging.properties
Usage examples
Here are some examples of using this option:
Use options read from a file named runner.args for the current directory (=directory Pax Runner was started):
pax-run --args=file:runner.argsUse options read from a file named runner.args from
/home/foo/directory:pax-run --args=file:/home/foo/runner.argsUse options read from the web
pax-run --args=http://somewhere.org/foo
Disable arguments file lookup
If you do not specify the --args options and you do not want Pax Runner to look by default in the current directory for runner.args file, you can use the --noArgs. option.
pax-run --noArgs
This feature is only available starting with release 0.16.0 of Pax Runner.