Skip to content

Commit

Permalink
docs: new documentation page
Browse files Browse the repository at this point in the history
  • Loading branch information
SteKoe committed Dec 6, 2024
1 parent 18318d2 commit 56431ea
Show file tree
Hide file tree
Showing 98 changed files with 23,844 additions and 3,265 deletions.
3 changes: 3 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ root = true
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
trim_trailing_whitespace = false

[*.java]
indent_style = tab
indent_size = 4
Expand Down
16 changes: 16 additions & 0 deletions .github/workflows/build-feature.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,19 @@ jobs:
- uses: codecov/codecov-action@v5
with:
files: "'*/jacoco.xml'"

- name: Extract Maven project version for Asciidoc GitHub Pages directory naming
run: echo ::set-output name=version::$(mvn -q -Dexec.executable=echo -Dexec.args='${project.version}' --non-recursive exec:exec)
id: project

- name: Show extracted Maven project version
run: echo ${{ steps.project.outputs.version }}

- name: Deploy Asciidoc docs output to GitHub Pages
uses: JamesIves/[email protected]
with:
branch: gh-pages # The branch the action should deploy to.
folder: spring-boot-admin-docs/target/generated-docs # The folder the action should deploy.
target-folder: ${{ steps.project.outputs.version }}
clean: true # Automatically remove deleted files from the deploy branch

143 changes: 143 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,7 @@
<checkstyle.version>10.20.2</checkstyle.version>
<spring-javaformat-checkstyle.version>0.0.43</spring-javaformat-checkstyle.version>
<nexus-staging-maven-plugin.version>1.7.0</nexus-staging-maven-plugin.version>
<node.version>v18.20.2</node.version>
<npm.version>10.5.2</npm.version>
<node.version>v22.12.0</node.version>
<jolokia-support-spring.version>2.1.2</jolokia-support-spring.version>
</properties>
<modules>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,19 @@
import org.springframework.boot.cloud.CloudPlatform;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.convert.DurationUnit;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.env.Environment;
import org.springframework.lang.Nullable;

@lombok.Data
@ConfigurationProperties(prefix = "spring.boot.admin.client")
@Configuration
@ConfigurationProperties("spring.boot.admin.client")
public class ClientProperties {

/**
* The admin server urls to register at
*/
private String[] url = new String[] {};
private String[] url = new String[0];

/**
* The admin rest-apis path.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,12 @@

import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;
import org.springframework.lang.Nullable;

@lombok.Data
@ConfigurationProperties(prefix = "spring.boot.admin.client.instance")
@Configuration
@ConfigurationProperties("spring.boot.admin.client.instance")
public class InstanceProperties {

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,17 @@
{"groups": [

],"properties": [
{
"name": "spring.boot.admin.client.enabled",
"type": "java.lang.Boolean",
"description": "Enable Spring Admin Client.",
"defaultValue": "true"
}
]}
{
"groups": [
{
"name": "spring.boot.admin.client",
"type": "de.codecentric.boot.admin.client.config.ClientProperties",
"sourceType": "de.codecentric.boot.admin.client.config.ClientProperties"
}
],
"properties": [
{
"name": "spring.boot.admin.client.enabled",
"type": "java.lang.Boolean",
"description": "Enable Spring Admin Client.",
"defaultValue": "true"
}
]
}
109 changes: 58 additions & 51 deletions spring-boot-admin-docs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
~ limitations under the License.
-->

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>spring-boot-admin-docs</artifactId>
Expand All @@ -29,66 +29,73 @@
<relativePath>../spring-boot-admin-build</relativePath>
</parent>

<properties>
<site.skin.version>2.3.3</site.skin.version>
</properties>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<!--
Due to changes in Doxia (see https://cwiki.apache.org/confluence/display/MAVEN/Towards+Doxia+2.0.0+Stack),
we have to use a fixed version here, as our site skin does not work with the latest version.
-->
<version>3.12.1</version>
<groupId>com.github.eirslett</groupId>
<artifactId>frontend-maven-plugin</artifactId>
<configuration>
<workingDirectory>src/site</workingDirectory>
<environmentVariables>
<NODE_ENV>production</NODE_ENV>
<VERSION>${project.version}</VERSION>
</environmentVariables>
</configuration>
<executions>
<execution>
<id>output-html</id>
<phase>generate-resources</phase>
<id>install-node-and-npm</id>
<goals>
<goal>install-node-and-npm</goal>
</goals>
<configuration>
<nodeVersion>${node.version}</nodeVersion>
</configuration>
</execution>
<execution>
<id>npm-install</id>
<phase>compile</phase>
<goals>
<goal>npm</goal>
</goals>
<configuration>
<arguments>ci --prefer-offline --no-audit</arguments>
</configuration>
</execution>
<execution>
<id>npm-build</id>
<phase>prepare-package</phase>
<goals>
<goal>site</goal>
<goal>npm</goal>
</goals>
<configuration>
<outputDirectory>target/generated-docs</outputDirectory>
<arguments>run build:prod</arguments>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.rodnansol</groupId>
<artifactId>spring-configuration-property-documenter-maven-plugin</artifactId>
<version>0.6.1</version>
<executions>
<execution>
<id>generate-adoc</id>
<goals>
<goal>generate-and-aggregate-documents</goal>
</goals>
<phase>generate-resources</phase>
<configuration>
<type>ADOC</type>
<inputs>
<input>
<name>spring-boot-admin-server</name>
<input>../spring-boot-admin-server</input>
</input>
</inputs>
<outputFile>target/aggregated-adoc.adoc</outputFile>
</configuration>
</execution>
</executions>
<configuration>
<!-- Disable generateReports if you don't want to include the built-in reports -->
<generateReports>false</generateReports>
<generateSitemap>false</generateSitemap>
<relativizeDecorationLinks>false</relativizeDecorationLinks>
<inputEncoding>UTF-8</inputEncoding>
<outputEncoding>UTF-8</outputEncoding>
<asciidoc>
<!-- Optional site-wide AsciiDoc attributes -->
<attributes>
<icons>font</icons>
<source-highlighter>coderay</source-highlighter>
<commit-id>${git.commit.id.abbrev}</commit-id>
<commit-time>${git.commit.time}</commit-time>
<project-version>${project.version}</project-version>
<spring-cloud-version>${spring-cloud.version}</spring-cloud-version>
<samples-dir>${basedir}/../spring-boot-admin-samples/</samples-dir>
<main-dir>${basedir}/../</main-dir>
<github-src>https://github.com/codecentric/spring-boot-admin/tree/master</github-src>
</attributes>
</asciidoc>
</configuration>
<dependencies>
<dependency>
<groupId>com.bernardomg.maven.skins</groupId>
<artifactId>docs-maven-skin</artifactId>
<version>${site.skin.version}</version>
</dependency>
<dependency>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctor-converter-doxia-module</artifactId>
<version>${asciidoctor-converter-doxia-module.version}</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
Expand All @@ -98,7 +105,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>3.8.0</version>
<version>3.4.2</version>
</plugin>
</plugins>
</reporting>
Expand Down
Loading

0 comments on commit 56431ea

Please sign in to comment.