Package io.micronaut.build
Class AbstractDockerMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- io.micronaut.build.AbstractDockerMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
- Direct Known Subclasses:
DockerfileMojo,DockerMojo,DockerNativeMojo,DockerPushMojo
public abstract class AbstractDockerMojo extends org.apache.maven.plugin.AbstractMojoAbstract base class for mojos related to Docker files and builds.- Since:
- 1.1
- Author:
- Álvaro Sánchez-Mariscal
-
-
Field Summary
Fields Modifier and Type Field Description protected List<String>appArgumentsList of additional arguments that will be passed to the application.protected ApplicationConfigurationServiceapplicationConfigurationServiceprotected DockerServicedockerServiceprotected JibConfigurationServicejibConfigurationServiceprotected StringmainClassThe main class of the application, as defined in the Exec Maven Plugin.protected org.apache.maven.project.MavenProjectmavenProjectprotected StringmicronautRuntimeThe target runtime of the applicationprotected StringnativeImageBuildArgsAdditional arguments that will be passed to thenative-imageexecutable.protected BooleanstaticNativeImageWhether to produce a static native image when usingdocker-nativepackaging
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractDockerMojo(org.apache.maven.project.MavenProject mavenProject, JibConfigurationService jibConfigurationService, ApplicationConfigurationService applicationConfigurationService, DockerService dockerService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidcopyDependencies()protected StringgetCmd()protected StringgetFrom()protected StringgetPort()protected Set<String>getTags()protected StringgraalVmJvmVersion()protected StringgraalVmVersion()protected org.apache.maven.artifact.versioning.ArtifactVersionjavaVersion()-
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
-
-
-
Field Detail
-
mavenProject
protected final org.apache.maven.project.MavenProject mavenProject
-
jibConfigurationService
protected final JibConfigurationService jibConfigurationService
-
applicationConfigurationService
protected final ApplicationConfigurationService applicationConfigurationService
-
dockerService
protected final DockerService dockerService
-
nativeImageBuildArgs
@Parameter(property="micronaut.native-image.args") protected String nativeImageBuildArgs
Additional arguments that will be passed to thenative-imageexecutable. Note that this will only be used when using a packaging of typedocker-native. Fornative-imagepackaging you should use the Native Image Maven Plugin configuration options.
-
appArguments
@Parameter(property="mn.appArgs") protected List<String> appArguments
List of additional arguments that will be passed to the application.
-
mainClass
@Parameter(defaultValue="${exec.mainClass}", required=true) protected String mainClassThe main class of the application, as defined in the Exec Maven Plugin.
-
staticNativeImage
@Parameter(defaultValue="false", property="micronaut.native-image.static") protected Boolean staticNativeImageWhether to produce a static native image when usingdocker-nativepackaging
-
micronautRuntime
@Parameter(property="micronaut.runtime", defaultValue="NONE") protected String micronautRuntimeThe target runtime of the application
-
-
Constructor Detail
-
AbstractDockerMojo
protected AbstractDockerMojo(org.apache.maven.project.MavenProject mavenProject, JibConfigurationService jibConfigurationService, ApplicationConfigurationService applicationConfigurationService, DockerService dockerService)
-
-
Method Detail
-
javaVersion
protected org.apache.maven.artifact.versioning.ArtifactVersion javaVersion()
-
graalVmVersion
protected String graalVmVersion()
-
graalVmJvmVersion
protected String graalVmJvmVersion()
-
getFrom
protected String getFrom()
-
getPort
protected String getPort()
-
copyDependencies
protected void copyDependencies() throws IOException- Throws:
IOException
-
getCmd
protected String getCmd()
-
-