Skip to content

Releases: steklopod/gradle-docker-plugin

1.1.0 is here

26 Dec 12:12
Compare
Choose a tag to compare

Available tasks for docker plugin:

  • deploy - compose up project from docker-compose.yml file (default with recreate & rebuild)
  • deployDev - compose up docker container from docker-compose.dev.yml file
  • recompose, recomposeDev - compose up after removing current docker-service
  • stop, remove - stop/remove docker container
  • logs, docker - print current docker-services

deploy is easy

26 Nov 18:37
Compare
Choose a tag to compare

Gradle docker plugin Build StatusQuality Gate Status

πŸ›‘οΈ docker - gradle plugin for projects with any types and languages.
It gives helpful gradle's tasks for working with docker containers.

Quick start

  1. You only need to have docker-compose.yml file in root of project

  2. In your build.gradle.kts file:

plugins {
     id("online.colaba.docker") version "0.2.2"
}

Run 🎯

./gradlew deploy

this task is equivalent to docker-compose up --build --force-recreate -d command.

Available gradle's tasks for docker plugin:

Name of service for all tasks equals to ${project.name}. You can customize options of each task.

  • containers - print current docker-services;
  • deploy - compose up docker-service;
  • stop - stops docker-container;
  • remove - removes docker-service;
  • redeploy - compose up after removing current docker-service.

Example 🎫

  • Structure
hello
     |  - build.gradle.kts
     |  - docker-compose.yml
     |  - docker-compose.dev.yml (optional)
  • docker-compose.yml file
version: "3.7"
services:
  hello:
    image: hello-world
    container_name: hello

Optional

docker-compose.dev.yml, Dockerfile & Dockerfile.dev files are optionals.

Optional tasks:

  • deployDev - compose up docker-service from docker-compose.dev.yml file;
  • redeployDev - compose up after removing current docker-service from docker-compose.dev.yml file.

0.1.1

16 Nov 18:13
Compare
Choose a tag to compare

Quickstart

You only need to have docker-compose.yml file in root of project

In your buildgradle.kt file:

plugins {
     id("online.colaba.docker") version "0.1.1"
}

Init version

16 Nov 18:04
Compare
Choose a tag to compare

Gradle docker-plugin Build Status

πŸ›‘οΈ Gradle docker plugin for projects with types and languages

Quickstart

You only need to have docker-compose.yml file in root of project

In your buildgradle.kt file:

plugins {
     id("online.colaba.docker") version "0.1"
}

Available docker-tasks for docker-plugin:

Name of service for all tasks equalse to ${project.name}

gradle stop - stops docker-container

gradle containers - print current docker-services

gradle remove - removes docker-service

gradle deploy - compose up docker-service from docker-compose.ymlfile

gradle deployDev - compose up docker-service from docker-compose.dev.yml file [optional]

gradle redeploy - compose up after removing current docker-service

gradle redeployDev -- compose up after removing current docker-service from docker-compose.dev.yml file [optional]

Apply only for subprojects

subprojects {
    apply<Docker>()
    registerExecutorTask()
}

docker-compose.yml & Dockerfile files are optionals.