Search code examples
spring-bootspring-boot-admin

Spring Boot Admin - How to show app version (build-info) in wallboard?


I see on the web some images refferred to Spring Boot Admin showing the app version in the wallboard page.

I'm using latest version of SBA, currently 2.1.6 and i can't see the versions in the wallboard.
I see something like this.

Reading the documentation it seems that a maven plugin is needed:

<build>
    <plugins>
        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>
            <executions>
                <execution>
                    <goals>
                        <goal>build-info</goal>
                    </goals>
                </execution>
            </executions>
        </plugin>
    </plugins>
</build>

I added it in the pom.xml of a micro-service and I restarted all docker swarms stacks (including SBA) but no changes.
I did some search but I can't find any reference.


Solution

  • The 'spring-boot-maven-plugin' is required to generate the build-info in

    /target/classes/META-INF/build-info.properties

    Spring Boot Admin picks up the build info including the application version from this file. Please check if this file is generated. You need to execute the maven plugin first or just run

     mvn clean install
    

    enter image description here