ios: direct logs to ios/logs, archive on failure

This way people don't have to ask me for access to logs from CI hosts to
be acquired using SSH access, but instead they will be simply included
in Jenkins build artifacts.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
Jakub Sokołowski 2023-03-09 11:07:56 +01:00
parent 8d7224d972
commit 8cd5e3f6e3
No known key found for this signature in database
GPG Key ID: FE65CD384D5BF7B4
4 changed files with 12 additions and 7 deletions

3
.gitignore vendored
View File

@ -100,9 +100,8 @@ Statusgo.xcframework
#ios #ios
/ios/Pods/ /ios/Pods/
/ios/logs/
/ios/StatusIm.xcworkspace /ios/StatusIm.xcworkspace
/ios/react-native-xcode.log
/ios/set_xcode_version.log
.ruby-version .ruby-version
status-e2e/ status-e2e/

View File

@ -63,6 +63,9 @@ pipeline {
steps { steps {
script { api = ios.bundle() } script { api = ios.bundle() }
} }
post {
failure { archiveArtifacts 'ios/logs/*' }
}
} }
stage('Parallel Upload') { stage('Parallel Upload') {
parallel { parallel {

View File

@ -123,6 +123,7 @@ def build_ios_adhoc(readonly: false, pr_build: false)
export_method: 'ad-hoc', export_method: 'ad-hoc',
output_name: 'StatusIm', output_name: 'StatusIm',
output_directory: 'status-ios', output_directory: 'status-ios',
buildlog_path: 'ios/logs',
export_options: { export_options: {
signingStyle: 'manual', signingStyle: 'manual',
provisioningProfiles: { provisioningProfiles: {
@ -162,6 +163,7 @@ def build_ios_e2e
# 3. directory where to up StatusIm.app # 3. directory where to up StatusIm.app
derived_data_path: 'status-ios', derived_data_path: 'status-ios',
output_name: 'StatusIm.app', output_name: 'StatusIm.app',
buildlog_path: 'ios/logs',
# ------------------------------------- # -------------------------------------
# Normal stuff # Normal stuff
scheme: 'StatusIm', scheme: 'StatusIm',
@ -239,6 +241,7 @@ platform :ios do
clean: true, clean: true,
export_method: 'app-store', export_method: 'app-store',
output_directory: 'status-ios', output_directory: 'status-ios',
buildlog_path: 'ios/logs',
include_symbols: false, include_symbols: false,
export_options: { export_options: {
"combileBitcode": true, "combileBitcode": true,

View File

@ -526,7 +526,7 @@
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
shellPath = "/usr/bin/env sh"; shellPath = "/usr/bin/env sh";
shellScript = "set -o errexit\nexport NODE_BINARY=\"${NODE_BINARY:-node}\"\nexport NODE_ARGS=\" --openssl-legacy-provider --max-old-space-size=16384 \"\n\nbash -x ../node_modules/react-native/scripts/react-native-xcode.sh > ./react-native-xcode.log 2>&1"; shellScript = "set -o errexit\nexport NODE_BINARY=\"${NODE_BINARY:-node}\"\nexport NODE_ARGS=\" --openssl-legacy-provider --max-old-space-size=16384 \"\n\nbash -x ../node_modules/react-native/scripts/react-native-xcode.sh > ./logs/react-native-xcode.log 2>&1";
}; };
0F876BD5356F61BF142A01A0 /* [CP] Check Pods Manifest.lock */ = { 0F876BD5356F61BF142A01A0 /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;
@ -584,7 +584,7 @@
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
shellPath = "/usr/bin/env sh"; shellPath = "/usr/bin/env sh";
shellScript = "set -o errexit\nexport NODE_BINARY=\"${NODE_BINARY:-node}\"\nexport NODE_ARGS=\" --openssl-legacy-provider --max-old-space-size=16384 \"\n\nbash -x ../node_modules/react-native/scripts/react-native-xcode.sh > ./react-native-xcode.log 2>&1"; shellScript = "set -o errexit\nexport NODE_BINARY=\"${NODE_BINARY:-node}\"\nexport NODE_ARGS=\" --openssl-legacy-provider --max-old-space-size=16384 \"\n\nbash -x ../node_modules/react-native/scripts/react-native-xcode.sh > ./logs/react-native-xcode.log 2>&1";
}; };
3AAD2AD724A3A60E0075D594 /* Run Script */ = { 3AAD2AD724A3A60E0075D594 /* Run Script */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;
@ -598,7 +598,7 @@
); );
runOnlyForDeploymentPostprocessing = 1; runOnlyForDeploymentPostprocessing = 1;
shellPath = "/usr/bin/env sh"; shellPath = "/usr/bin/env sh";
shellScript = "\"${PROJECT_DIR}/scripts/set_xcode_version.sh\" > ./set_xcode_version.log 2>&1"; shellScript = "\"${PROJECT_DIR}/scripts/set_xcode_version.sh\" > ./logs/set_xcode_version.log 2>&1";
}; };
3C1038075AE5E6FB86AC2319 /* [CP] Copy Pods Resources */ = { 3C1038075AE5E6FB86AC2319 /* [CP] Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;
@ -678,7 +678,7 @@
); );
runOnlyForDeploymentPostprocessing = 1; runOnlyForDeploymentPostprocessing = 1;
shellPath = "/usr/bin/env sh"; shellPath = "/usr/bin/env sh";
shellScript = "\"${PROJECT_DIR}/scripts/set_xcode_version.sh\" > ./set_xcode_version.log 2>&1"; shellScript = "\"${PROJECT_DIR}/scripts/set_xcode_version.sh\" > ./logs/set_xcode_version.log 2>&1";
}; };
E732E3E1B024946173BF6D3D /* [CP] Copy Pods Resources */ = { E732E3E1B024946173BF6D3D /* [CP] Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;