https://bmuschko.github.io/gradle-docker-plugin/
I am trying to use HEALTHCHECK inside build.gradle using the above gradle-docker-plugin for a spring-boot app as following.
docker {
springBootApplication {
baseImage = 'docker.infy.com:4443/containers/openjdk-11jre:latest'
maintainer = "astra-aws-dev@infy.com, ic-pe@infy.com"
ports = [8080]
images = ["infy/${project.name}:latest"]
jvmArgs = ['-server', '-Dathenz.zpe.policy_dir=/var/zpe', 'Dathenz.athenz_conf=/etc/athenz/athenz.conf']
instruction = 'HEALTHCHECK CMD wget --quiet --tries=1 --spider http://localhost:8080/actuator/health || exit 1'
}
}
I am referring to the plugin-user-guide at 2.5.2 of https://bmuschko.github.io/gradle-docker-plugin/current/user-guide/ to configure the healthcheck of the container. But for springbootapplication extension, it throws an error saying "instruction" is an unknown property. Please help me resolve this. Thanks in advance.