Add CI build shell scripts.
This commit is contained in:
6
ci/check.sh
Executable file
6
ci/check.sh
Executable file
@@ -0,0 +1,6 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -eou pipefail
|
||||
|
||||
GRADLE_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home -Djava.io.tmpdir=/tmp" \
|
||||
./gradlew clean check --no-daemon --refresh-dependencies --stacktrace
|
||||
7
ci/cleanupArtifacts.sh
Executable file
7
ci/cleanupArtifacts.sh
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
rm -Rf ./.gradle
|
||||
rm -Rf ./.m2
|
||||
rm -Rf `find . -name "build" | grep -v "src"`
|
||||
rm -Rf `find . -name "target" | grep -v "src"`
|
||||
exit 0
|
||||
9
ci/cleanupGemFiles.sh
Executable file
9
ci/cleanupGemFiles.sh
Executable file
@@ -0,0 +1,9 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
rm -Rf `find . -name "BACKUPDEFAULT*"`
|
||||
rm -Rf `find . -name "ConfigDiskDir*"`
|
||||
rm -Rf `find . -name "locator*" | grep -v "src" | grep -v "locator-application"`
|
||||
rm -Rf `find . -name "newDB"`
|
||||
rm -Rf `find . -name "server" | grep -v "src"`
|
||||
rm -Rf `find . -name "*.log"`
|
||||
exit 0
|
||||
20
ci/deployArtifacts.sh
Executable file
20
ci/deployArtifacts.sh
Executable file
@@ -0,0 +1,20 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -eou pipefail
|
||||
|
||||
echo "Deploying artifacts on host [$HOSTNAME]"
|
||||
|
||||
# User ID 1001 is "jenkins"
|
||||
# Group ID 1001 is "jenkins"
|
||||
# Syntax: `chown -R userId:groupId .`
|
||||
chown -R 1001:1001 .
|
||||
|
||||
GRADLE_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home -Djava.io.tmpdir=/tmp" \
|
||||
./gradlew deployArtifacts finalizeDeployArtifacts --no-build-cache --no-configuration-cache --no-daemon --stacktrace \
|
||||
-PartifactoryUsername=$ARTIFACTORY_USERNAME \
|
||||
-PartifactoryPassword=$ARTIFACTORY_PASSWORD \
|
||||
-PossrhUsername=$OSSRH_USERNAME \
|
||||
-PossrhPassword=$OSSRH_PASSWORD \
|
||||
-Psigning.keyId=$SPRING_SIGNING_KEYID \
|
||||
-Psigning.password=$SIGNING_PASSWORD \
|
||||
-Psigning.secretKeyRingFile=$SIGNING_KEYRING_FILE
|
||||
15
ci/deployDocs.sh
Executable file
15
ci/deployDocs.sh
Executable file
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -eou pipefail
|
||||
|
||||
echo "Deploying docs on host [$HOSTNAME]"
|
||||
|
||||
# User ID 1001 is "jenkins"
|
||||
# Group ID 1001 is "jenkins"
|
||||
# Syntax: `chown -R userId:groupId .`
|
||||
chown -R 1001:1001 .
|
||||
|
||||
GRADLE_OPTS="--add-opens java.base/java.io=ALL-UNNAMED --add-opens java.base/sun.nio.ch=ALL-UNNAMED -Duser.name=jenkins -Duser.home=/tmp/jenkins-home -Djava.io.tmpdir=/tmp" \
|
||||
./gradlew deployDocs --no-daemon --stacktrace \
|
||||
-PdeployDocsSshKeyPath=$DEPLOY_SSH_KEY \
|
||||
-PdeployDocsSshUsername=$SPRING_DOCS_USERNAME
|
||||
11
ci/setup.sh
Executable file
11
ci/setup.sh
Executable file
@@ -0,0 +1,11 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
# User ID 1001 is "jenkins"
|
||||
# Group ID 1001 is "jenkins"
|
||||
# Syntax: `chown -R userId:groupId .`
|
||||
|
||||
echo "Logged into Jenkins CI as user [$USER] with home directory [$HOME] in the current working directory [$PWD]"
|
||||
chown -R 1001:1001 .
|
||||
#echo "Logging into Docker..."
|
||||
#docker login --username ${DOCKER_HUB_USR} --password ${DOCKER_HUB_PSW}
|
||||
exit 0
|
||||
Reference in New Issue
Block a user