I'm using Gradle
with Spring Boot 2.0.0.M7
and have the following plugins applied:
buildscript {
repositories {
maven { url "https://plugins.gradle.org/m2/" }
maven { url "https://repo.spring.io/milestone" }
}
dependencies {
classpath "org.springframework.boot:spring-boot-gradle-plugin:2.0.0.M7"
}
}
plugins {
id "com.gorylenko.gradle-git-properties" version "1.4.17"
}
spring-boot-starter-actuator
dependency is also there. git.properties
files is generated correctly to build/main/resoures
directory. I've also added property management.info.git.mode=full
. Due to official docs, git information should be added to /info
endpoint automatically with GitInfoContributor. However none of the above helps and /info
endpoint returns empty JSON instead - {}
. Any ideas on how this can be fixed?
UPDATE 1:
What I've found so far is that if I manually copy git.properties
to out/resources
, this way it would work, but they are not put there for some reason.
UPDATE 2:
When I run with gradle bootRun
it works, however when I start it from Intellij IDEA our run gradle clean build
which runs the test which checks if those properties are displayed on /info
endpoint - it doesn't work.