Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current Restore this Version View Page History

« Previous Version 3 Next »

The runtime assembly plugin is used to provision a runtime image as part of an automated, reproducible Maven build process. The plugin downloads and provisions the Fabric3 standalone runtime and extensions along with application contributions. In addition, it can apply custom configuration to the runtime image.

The excerpt shows the basic plugin setup in a Maven POM file:

<plugins>
    <plugin>
        <groupId>org.codehaus.fabric3</groupId>
        <artifactId>fabric3-assembly-plugin</artifactId>
        <version>${fabric3.version}</version>
        <executions>
            <execution>
                <id>fabric3-assembly</id>
                <goals>
                    <goal>fabric3-assembly</goal>
                </goals>
            </execution>
        </executions>
        <configuration>
            <runtimeVersion>${fabric3.version}</runtimeVersion>
            ...
  </configuration>

    </plugin>
</plugins>
<plugins>
    <plugin>
        <groupId>org.codehaus.fabric3</groupId>
        <artifactId>fabric3-assembly-plugin</artifactId>
        <version>${fabric3.version}</version>
        <executions>
            <execution>
                <id>fabric3-assembly</id>
                <goals>
                    <goal>fabric3-assembly</goal>
                </goals>
            </execution>
        </executions>
        <configuration>
            <runtimeVersion>${fabric3.version}</runtimeVersion>
            <profiles>
                <!-- JMS support -->
                <profile>
                    <groupId>org.codehaus.fabric3</groupId>
                    <artifactId>profile-jms</artifactId>
                    <version>${fabric3.version}</version>
                </profile>
                <!-- JAX-RS support -->
                <profile>
                    <groupId>org.codehaus.fabric3</groupId>
                    <artifactId>profile-rs</artifactId>
                    <version>${fabric3.version}</version>
                </profile>
            </profiles>
            <!-- add contributions -->
			<contributions>
 <dependency>
                    <groupId>org.fabric3.samples</groupId>
                    <artifactId>gateway</artifactId>
                    <version>${app.version}</version>
				</dependency>
				<dependency>
                    <groupId>org.fabric3.samples</groupId>
                    <artifactId>backend</artifactId>
                    <version>${app.version}</version>
				</dependency>
			</contributions>
            <!-- overlay configuration -->
            <configurationFiles>
                <copy>
                    <source>../../../config/security.xml</source>
                    <destination>runtimes/vm/config</destination>
                </copy>
            </configurationFiles>
        </configuration>
    </plugin>
</plugins>