Fork me on GitHub

vagrant:box-add

Full name:

net.ju-n.maven.plugins:vagrant-maven-plugin:1.0.2:box-add

Description:

Invokes Vagrant box add command.

Attributes:

  • Requires a Maven project to be executed.
  • Since version: 1.0.

Required Parameters

Name Type Since Description
box String 1.0 Box name.
url String 1.0 VM URL.

Optional Parameters

Name Type Since Description
addProjectClasspath boolean 1.0 add project class path to JVM classpath on executing jruby.
Default value is: true.
User property is: jruby.addProjectClasspath.
args String 1.0 common arguments
User property is: args.
binDirectory File 1.0 directory of JRuby bin path to use when forking JRuby.
Command line -Dgem.binDirectory=...
User property is: gem.binDirectory.
eclipseRefresh List 1.0 (no description)
User property is: m2e.jruby.refresh.
eclipseWatches List 1.0 (no description)
User property is: m2e.jruby.watch.
env Map 1.0 environment values passed on to the jruby process. needs jrubyFork true.
User property is: jruby.env.
force boolean 1.0 Overwrite an existing box if it exists.
Default value is: false.
gemHome File 1.0 Custom gems directory. Modifying this property has an impact on isolation/build portability, eg:
  • In project.build.directory (default): user installation can not impact build, but gems are unpacked at every build.
  • In project.basedir: user installation can not impact build, gems are unpacked once for all, but files are created outside of build directory.
  • Outside project.basedir (Vagrant default): user installation can impact build.

Default value is: ${project.build.directory}/vagrant/gems.
gemHomes Map 1.0 map different install locations for rubygems (GEM_HOME) to a directory. for example compile dependencies will be installed in ${project.build.directory}/rubygems and provided dependencies in ${project.build.directory}/rubygems-provided, and ${project.build.directory}/rubygems-test for the test scope. this mapping here allows to map those different directories onto a single one, i.e.: test => ${gem.home}, provided => ${gem.home}

User property is: gem.homes.
gemPath File 1.0 directory of JRuby path to use when forking JRuby. default will be ignored when gemUseSystem is true.
Command line -Dgem.path=...
Default value is: ${project.build.directory}/rubygems.
User property is: gem.path.
gemUseSystem boolean 1.0 use system gems instead of setting up GemPath/GemHome inside the build directory and ignores any set gemHome and gemPath. you need to have both GEM_HOME and GEM_PATH environment variable set to make it work.
Command line -Dgem.useSystem=...
Default value is: false.
User property is: gem.useSystem.
includeGemsInResources String 1.0 EXPERIMENTAL this gives the scope of the gems which shall be included to resources. flag whether to include all gems to resources, i.e. to classpath or not. the difference to the includeRubygemsInResources is that it does not depend on rubygems during runtime since the required_path of the gems gets added to resources. note that it expect the required_path of the gem to be lib which is the default BUT that is not true for all gems. in this sense this feature is incomplete and might not work for you !!! IMPORTANT: it only adds the gems with provided scope since they are packed with the jar and then the pom.xml will not have them (since they are marked 'provided') as transitive dependencies. this feature can be helpful in situations where the classloader does not work for rubygems due to rubygems uses file system globs to find the gems and this only works if the classloader reveals the jar url of its jars (i.e. URLClassLoader). for example OSGi classloader can not work with rubygems !!
Command line -Dgem.includeGemsInResources=...
User property is: gem.includeGemsInResources.
includeLibDirectoryInResources boolean 1.0 /** flag whether to include file under the lib directory
Command line -Dgem.includeLibDirectoryInResources=...
Default value is: false.
User property is: gem.includeLibDirectoryInResources.
includeOpenSSL boolean 1.0 flag whether to include open-ssl gem or not
Command line -Dgem.includeOpenSSL=...
Default value is: false.
User property is: gem.includeOpenSSL.
includeProvidedRubygemsInResources boolean 1.0 flag whether to include all gems to resources, i.e. to classpath or not
Command line -Dgem.includeProvidedRubygemsInResources=...
Default value is: false.
User property is: gem.includeProvidedRubygemsInResources.
includeRubygemsInResources boolean 1.0 flag whether to include all gems to resources, i.e. to classpath or not
Command line -Dgem.includeRubygemsInResources=...
Default value is: false.
User property is: gem.includeRubygemsInResources.
includeRubygemsInTestResources boolean 1.0 flag whether to include all gems to test-resources, i.e. to test-classpath or not
Command line -Dgem.includeRubygemsInTestResources=...
Default value is: true.
User property is: gem.includeRubygemsInTestResources.
installRDoc boolean 1.0 flag whether to install rdocs of the used gems or not
Command line -Dgem.installRDoc=...
Default value is: false.
User property is: gem.installRDoc.
installRI boolean 1.0 flag whether to install ri of the used gems or not
Command line -Dgem.installRDoc=...
Default value is: false.
User property is: gem.installRI.
jrubyFork boolean 1.0 fork the JRuby execution.
Default value is: true.
User property is: jruby.fork.
jrubyJvmArgs String 1.0 jvm arguments for the java command executing jruby
User property is: jruby.jvmargs.
jrubySwitches String 1.0 switches for the jruby command, like '--1.9'
User property is: jruby.switches.
jrubyVerbose boolean 1.0 verbose jruby related output
Default value is: false.
User property is: jruby.verbose.
jrubyVersion String 1.0 if the pom.xml has no runtime dependency to a jruby-complete.jar then this version is used to resolve the jruby-complete dependency from the local/remote maven repository. it overwrites the jruby version from the dependencies if any. i.e. you can easily switch jruby version from the commandline ! default see DEFAULT_JRUBY_VERSION
User property is: jruby.version.
launchDirectory File 1.0 the launch directory for the JRuby execution.
Default value is: ${project.basedir}.
User property is: jruby.launchDirectory.
libDirectory File 1.0 directory with ruby sources - added to ruby loadpath only
Default value is: lib.
User property is: jruby.lib.
rubySourceDirectory File 1.0 directory with ruby sources - added to java classpath and ruby loadpath
Default value is: src/main/ruby.
User property is: jruby.sourceDirectory.
supportNative boolean 1.0 flag to indicate to setup jruby's native support for C-extensions
Command line -Dgem.supportNative=...
Default value is: false.
User property is: gem.supportNative.
vagrantHome File 1.0 Custom VAGRANT_HOME, which is the directory where Vagrant boxes are stored. Modifying this property has an impact on isolation/build portability, eg:
  • In project.build.directory (default): boxes must be imported every time, but no file is created outside of build directory.
  • In project.basedir: boxes can be imported once for all, but files are created outside of build directory.
  • In ~/.vagrant.d (Vagrant default): user boxes can be directly used, but files are created outside of project structure.

Default value is: ${project.build.directory}/vagrant/vagrant.d.
vagrantRc File 1.0 Custom VAGRANT_RC, which is the configuration file used by Vagrant. Modifying this property has an impact on isolation/build portability, eg:
  • In project.build.directory (default): user installation can not impact build.
  • In project.basedir: user installation can not impact build.
  • In ~/.vagrantrc (Vagrant default): user installation can impact build.

Default value is: ${project.build.directory}/vagrant/vagrantrc.

Parameter Details

addProjectClasspath:

add project class path to JVM classpath on executing jruby.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: jruby.addProjectClasspath
  • Default: true

args:

common arguments
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • User Property: args

binDirectory:

directory of JRuby bin path to use when forking JRuby.
Command line -Dgem.binDirectory=...
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • User Property: gem.binDirectory

box:

Box name.
  • Type: java.lang.String
  • Since: 1.0
  • Required: Yes

eclipseRefresh:

(no description)
  • Type: java.util.List
  • Since: 1.0
  • Required: No
  • User Property: m2e.jruby.refresh

eclipseWatches:

(no description)
  • Type: java.util.List
  • Since: 1.0
  • Required: No
  • User Property: m2e.jruby.watch

env:

environment values passed on to the jruby process. needs jrubyFork true.
  • Type: java.util.Map
  • Since: 1.0
  • Required: No
  • User Property: jruby.env

force:

Overwrite an existing box if it exists.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • Default: false

gemHome:

Custom gems directory. Modifying this property has an impact on isolation/build portability, eg:
  • In project.build.directory (default): user installation can not impact build, but gems are unpacked at every build.
  • In project.basedir: user installation can not impact build, gems are unpacked once for all, but files are created outside of build directory.
  • Outside project.basedir (Vagrant default): user installation can impact build.
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • Default: ${project.build.directory}/vagrant/gems

gemHomes:

map different install locations for rubygems (GEM_HOME) to a directory. for example compile dependencies will be installed in ${project.build.directory}/rubygems and provided dependencies in ${project.build.directory}/rubygems-provided, and ${project.build.directory}/rubygems-test for the test scope. this mapping here allows to map those different directories onto a single one, i.e.: test => ${gem.home}, provided => ${gem.home}
  • Type: java.util.Map
  • Since: 1.0
  • Required: No
  • User Property: gem.homes

gemPath:

directory of JRuby path to use when forking JRuby. default will be ignored when gemUseSystem is true.
Command line -Dgem.path=...
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • User Property: gem.path
  • Default: ${project.build.directory}/rubygems

gemUseSystem:

use system gems instead of setting up GemPath/GemHome inside the build directory and ignores any set gemHome and gemPath. you need to have both GEM_HOME and GEM_PATH environment variable set to make it work.
Command line -Dgem.useSystem=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.useSystem
  • Default: false

includeGemsInResources:

EXPERIMENTAL this gives the scope of the gems which shall be included to resources. flag whether to include all gems to resources, i.e. to classpath or not. the difference to the includeRubygemsInResources is that it does not depend on rubygems during runtime since the required_path of the gems gets added to resources. note that it expect the required_path of the gem to be lib which is the default BUT that is not true for all gems. in this sense this feature is incomplete and might not work for you !!! IMPORTANT: it only adds the gems with provided scope since they are packed with the jar and then the pom.xml will not have them (since they are marked 'provided') as transitive dependencies. this feature can be helpful in situations where the classloader does not work for rubygems due to rubygems uses file system globs to find the gems and this only works if the classloader reveals the jar url of its jars (i.e. URLClassLoader). for example OSGi classloader can not work with rubygems !!
Command line -Dgem.includeGemsInResources=...
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • User Property: gem.includeGemsInResources

includeLibDirectoryInResources:

/** flag whether to include file under the lib directory
Command line -Dgem.includeLibDirectoryInResources=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.includeLibDirectoryInResources
  • Default: false

includeOpenSSL:

flag whether to include open-ssl gem or not
Command line -Dgem.includeOpenSSL=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.includeOpenSSL
  • Default: false

includeProvidedRubygemsInResources:

flag whether to include all gems to resources, i.e. to classpath or not
Command line -Dgem.includeProvidedRubygemsInResources=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.includeProvidedRubygemsInResources
  • Default: false

includeRubygemsInResources:

flag whether to include all gems to resources, i.e. to classpath or not
Command line -Dgem.includeRubygemsInResources=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.includeRubygemsInResources
  • Default: false

includeRubygemsInTestResources:

flag whether to include all gems to test-resources, i.e. to test-classpath or not
Command line -Dgem.includeRubygemsInTestResources=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.includeRubygemsInTestResources
  • Default: true

installRDoc:

flag whether to install rdocs of the used gems or not
Command line -Dgem.installRDoc=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.installRDoc
  • Default: false

installRI:

flag whether to install ri of the used gems or not
Command line -Dgem.installRDoc=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.installRI
  • Default: false

jrubyFork:

fork the JRuby execution.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: jruby.fork
  • Default: true

jrubyJvmArgs:

jvm arguments for the java command executing jruby
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • User Property: jruby.jvmargs

jrubySwitches:

switches for the jruby command, like '--1.9'
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • User Property: jruby.switches

jrubyVerbose:

verbose jruby related output
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: jruby.verbose
  • Default: false

jrubyVersion:

if the pom.xml has no runtime dependency to a jruby-complete.jar then this version is used to resolve the jruby-complete dependency from the local/remote maven repository. it overwrites the jruby version from the dependencies if any. i.e. you can easily switch jruby version from the commandline ! default see DEFAULT_JRUBY_VERSION
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • User Property: jruby.version

launchDirectory:

the launch directory for the JRuby execution.
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • User Property: jruby.launchDirectory
  • Default: ${project.basedir}

libDirectory:

directory with ruby sources - added to ruby loadpath only
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • User Property: jruby.lib
  • Default: lib

rubySourceDirectory:

directory with ruby sources - added to java classpath and ruby loadpath
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • User Property: jruby.sourceDirectory
  • Default: src/main/ruby

supportNative:

flag to indicate to setup jruby's native support for C-extensions
Command line -Dgem.supportNative=...
  • Type: boolean
  • Since: 1.0
  • Required: No
  • User Property: gem.supportNative
  • Default: false

url:

VM URL.
  • Type: java.lang.String
  • Since: 1.0
  • Required: Yes

vagrantHome:

Custom VAGRANT_HOME, which is the directory where Vagrant boxes are stored. Modifying this property has an impact on isolation/build portability, eg:
  • In project.build.directory (default): boxes must be imported every time, but no file is created outside of build directory.
  • In project.basedir: boxes can be imported once for all, but files are created outside of build directory.
  • In ~/.vagrant.d (Vagrant default): user boxes can be directly used, but files are created outside of project structure.
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • Default: ${project.build.directory}/vagrant/vagrant.d

vagrantRc:

Custom VAGRANT_RC, which is the configuration file used by Vagrant. Modifying this property has an impact on isolation/build portability, eg:
  • In project.build.directory (default): user installation can not impact build.
  • In project.basedir: user installation can not impact build.
  • In ~/.vagrantrc (Vagrant default): user installation can impact build.
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • Default: ${project.build.directory}/vagrant/vagrantrc