tirithel / sbt-kind   0.1.0

GitHub

sbt plugin to publish locally to kind.

Scala versions: 2.12
sbt plugins: 1.x

sbt-kind

sbt-kind is a sbt plugin that loads built Docker images for your project into a kind cluster for local development.

Requirements

Setup

Add sbt-kind as a dependency in project/plugins.sbt:

addSbtPlugin("org.cmoran" % "sbt-kind" % "0.1.0")

Enable the plugin:

lazy val `project-module` = (project in file("."))
  .enablePlugins(KindPlugin)

Useful Keys & Command

The below settings will attempt to use your username as the cluster as well as upload all docker images made by the current build of the project.

import scala.sys.process._

val commonKindSettings = Seq(
    kind / clusterName      := ("whoami" !!).strip,
    kind / dockerImageNames := (docker / imageNames).value.map(_.toString()),
)
addCommandAlias("publishKind", "clean; test; docker; kind; ")
$ sbt publishKind