Commit e89c991d by Johannes Edmeier

use branch/tag for docs folder

parent 908e4568
......@@ -11,22 +11,21 @@
##
set -o errexit -o nounset
PROJECT_VERSION=$1
GH_URL="https://${GH_TOKEN}@github.com/codecentric/spring-boot-admin.git"
TEMPDIR="$(mktemp -d /tmp/gh-pages.XXX)"
TARGET_DIR="${TRAVIS_BRANCH/master/current}"
echo "Cloning gh-pages branch..."
git clone --branch gh-pages --single-branch --depth 1 --config user.name="Johannes Edmeier" --config user.email="johannes.edmeier@gmail.com" "$GH_URL" "$TEMPDIR"
git clone --branch gh-pages --single-branch --depth 1 --config user.name="Johannes Edmeier" --config user.email="johannes.edmeier@codecentric.de" "$GH_URL" "$TEMPDIR"
if [[ -d "$TEMPDIR"/"${PROJECT_VERSION}-SNAPSHOT" ]]; then
echo "Removing ${PROJECT_VERSION}-SNAPSHOT..."
rm -rf "$TEMPDIR"/"${PROJECT_VERSION}-SNAPSHOT"
if [[ -d "$TEMPDIR"/"${TARGET_DIR}" ]]; then
echo "Cleaning ${TARGET_DIR}..."
rm -rf "$TEMPDIR"/"${TARGET_DIR}"
fi
echo "Copying new docs..."
mkdir -p "$TEMPDIR"/"${PROJECT_VERSION}"
cp -r target/generated-docs/* "$TEMPDIR"/"${PROJECT_VERSION}"/
mkdir -p "$TEMPDIR"/"${TARGET_DIR}"
cp -r target/generated-docs/* "$TEMPDIR"/"${TARGET_DIR}"/
pushd "$TEMPDIR" >/dev/null
git add --all .
......@@ -35,7 +34,7 @@ if git diff-index --quiet HEAD; then
echo "No changes detected."
else
echo "Commit changes..."
git commit --message "Docs for ${PROJECT_VERSION}"
git commit --message "Docs for ${TARGET_DIR}"
echo "Pushing gh-pages..."
git push origin gh-pages
fi
......@@ -43,4 +42,4 @@ fi
popd >/dev/null
rm -rf "$TEMPDIR"
exit 0
exit 0
......@@ -66,9 +66,6 @@
</goals>
<configuration>
<executable>./deploy-gh-pages.sh</executable>
<arguments>
<argument>${project.version}</argument>
</arguments>
</configuration>
</execution>
</executions>
......
......@@ -48,7 +48,11 @@ For applications using older versions of Spring Boot the loglevel management is
[source,xml]
.logback-spring.xml
----
include::{samples-dir}/spring-boot-admin-sample/src/main/resources/logback-spring.xml[]
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<include resource="org/springframework/boot/logging/logback/base.xml"/>
<jmxConfigurator/>
</configuration>
----
NOTE: In case you are deploying multiple applications to the same JVM and multiple Logback-JMX-beans are present, the UI will select the JMXConfigurator with the context-name equals to your applications name. In this case you need to set the `contextName` in your logback-configuration.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment