Class DockerPlugin

java.lang.Object
io.github.pgatzka.docker.DockerPlugin
All Implemented Interfaces:
org.gradle.api.Plugin<org.gradle.api.Project>

public class DockerPlugin extends Object implements org.gradle.api.Plugin<org.gradle.api.Project>
Entry point for the io.github.pgatzka.docker Gradle plugin. Creates the docker {} extension, registers the shared DockerService, and registers lifecycle tasks (start/stop/remove containers, create/remove volumes and networks) per declared spec. Cross-spec validation is deferred to project.afterEvaluate(...).
  • Constructor Summary

    Constructors
    Constructor
    Description
    Public no-arg constructor invoked by Gradle when applying the plugin.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    apply(org.gradle.api.Project project)
    Apply the plugin to project: install the docker extension, register the shared DockerService, and register tasks for each declared container, volume, and network.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • DockerPlugin

      public DockerPlugin()
      Public no-arg constructor invoked by Gradle when applying the plugin.
  • Method Details

    • apply

      public void apply(org.gradle.api.Project project)
      Apply the plugin to project: install the docker extension, register the shared DockerService, and register tasks for each declared container, volume, and network. Container start tasks auto-depend on the create tasks of any volumes and networks they reference.
      Specified by:
      apply in interface org.gradle.api.Plugin<org.gradle.api.Project>
      Parameters:
      project - the project to apply the plugin to