Skip to content

Commit 0961c10

Browse files
committedMar 17, 2021
Jenkins: Provide SENTRY_DSN build-time environment variable
1 parent 7c81dac commit 0961c10

File tree

4 files changed

+9
-0
lines changed

4 files changed

+9
-0
lines changed
 

‎Jenkins/Jenkinsfile

+1
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ pipeline {
4545
GIT_BRANCH = "${sh(script:"echo ${env.BRANCH_NAME} | sed 's#^refs/heads/##g' | tr / - | tr [:upper:] [:lower:]", returnStdout: true).trim()}"
4646
OUTPUT_SUFFIX = "${GIT_BRANCH}-${JENKINS_BUILD_ID}"
4747
CODE_SIGNING_FILE = "/dev/urandom"
48+
SENTRY_DSN = credentials("SIMULATOR_SENTRY_DSN")
4849
}
4950

5051
stages {

‎Jenkins/Jenkinsfile-Release

+1
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ pipeline {
3434
OUTPUT_SUFFIX = "${sh(script:"echo ${env.GIT_TAG} | sed 's#^refs/tags/##g' | tr / - | tr [:upper:] [:lower:]", returnStdout: true).trim()}"
3535
CODE_SIGNING_FILE = "/dev/urandom"
3636
FORCE_REBUILD = "${FORCE_REBUILD}"
37+
SENTRY_DSN = credentials("SIMULATOR_SENTRY_DSN_RELEASE")
3738
}
3839

3940
stages {

‎Jenkins/build-simulator.sh

+6
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,12 @@ else
8181
NPCS=
8282
fi
8383

84+
if [ -n ${SENTRY_DSN} ]; then
85+
echo "SENTRY_DSN=${SENTRY_DSN}"
86+
else
87+
echo "Warning: SENTRY_DSN is not set"
88+
fi
89+
8490
function check_unity_log {
8591
${CHECK_UNITY_LOG} $@
8692
}

‎Jenkins/docker-compose.yml

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ services:
1717
- GIT_COMMIT
1818
- GIT_BRANCH
1919
- GIT_TAG
20+
- SENTRY_DSN
2021
- UNITY_USERNAME
2122
- UNITY_PASSWORD
2223
- UNITY_SERIAL

0 commit comments

Comments
 (0)
Please sign in to comment.