Plugin Documentation

Goals available for this plugin:

Goal Description
mn:docker

Allows using a provided Dockerfile.

WARNING: this goal is not intended to be executed directly. Instead, specify the packaging type using the packaging property, eg:

mvn package -Dpackaging=docker
mn:docker-native

Implementation of the docker-native packaging.

WARNING: this goal is not intended to be executed directly. Instead, specify the packaging type using the packaging property, eg:

mvn package -Dpackaging=docker-native
mn:docker-push

Implementation of the deploy lifecycle for pushing Docker images

WARNING: this goal is not intended to be executed directly. Instead, Execute the deploy phase specifying the packaging type, eg:

mvn deploy -Dpackaging=docker-native
mn:dockerfile

Generates a Dockerfile depending on the packaging and micronaut.runtime properties, eg:

mvn mn:dockerfile -Dpackaging=docker-native -Dmicronaut.runtime=lambda
mn:help Display help information on micronaut-maven-plugin.
Call mvn mn:help -Ddetail=true -Dgoal=<goal-name> to display parameter details.
mn:run

Executes a Micronaut application in development mode.

It watches for changes in the project tree. If there are changes in the pom.xml file, dependencies will be reloaded. If the changes are anywhere underneath src/main, it will recompile the project and restart the application.

The plugin can handle changes in all the languages supported by Micronaut: Java, Kotlin and Groovy.

System Requirements

The following specifies the minimum requirements to run this Maven plugin:

Maven 3.3.9
JDK 1.8
Memory No minimum requirement.
Disk Space No minimum requirement.

Usage

You should specify the version in your project's plugin configuration:

<project>
  ...
  <build>
    <!-- To define the plugin version in your parent POM -->
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>io.micronaut.build</groupId>
          <artifactId>micronaut-maven-plugin</artifactId>
          <version>1.1.0</version>
        </plugin>
        ...
      </plugins>
    </pluginManagement>
    <!-- To use the plugin goals in your POM or parent POM -->
    <plugins>
      <plugin>
        <groupId>io.micronaut.build</groupId>
        <artifactId>micronaut-maven-plugin</artifactId>
        <version>1.1.0</version>
      </plugin>
      ...
    </plugins>
  </build>
  ...
</project>

For more information, see "Guide to Configuring Plug-ins"