Create Docker Image on SBT task.
First, you write plugin.sbt
addSbtPlugin("net.numa08" % "docker-plugin" % "0.1")
Second, write docker setting in build.sbt
// Path for your Dockerfile
dockerPath = "./"
dockerTag = s"my-image:${version}"
dockerRegistry = Seq["numa08", "my-registry.com:5000"]
Third, run command in sbt
$sbt dockerBuild dockerPush
then, this plugin build docker image (tagged my-image:1.0
and my-image:latest
) and push to registry ( numa08/my-image
and my-registry.com:5000/my-image
)