Skip to content

Commit c05cac2

Browse files
committed
ios: produce signed build
- update status-jenkins-lib to v1.9.30 which provides iOS provisioning profile and appstore certs. - builds signed iOS app and pushes to testflight. - updates testflight metadata with PR link and commit sha it was built from - adds `scripts/testflight-changelog.mjs` script used by CI to update PR metadata. - set `ITSAppUsesNonExemptEncryption` to `false`
1 parent 8cbd78f commit c05cac2

22 files changed

+567
-47
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,3 +113,4 @@ ui/StatusQ/src/StatusQ/Core/TestConfig.qml
113113
mobile/bin/
114114
mobile/lib/
115115
mobile/build/
116+
scripts/node_modules/

ci/Jenkinsfile.android

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env groovy
2-
library '[email protected].29'
2+
library '[email protected].30'
33

44
/* Options section can't access functions in objects. */
55
def isPRBuild = utils.isPRBuild()

ci/Jenkinsfile.combined

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env groovy
22

3-
library '[email protected].29'
3+
library '[email protected].30'
44

55
/* Object to store public URLs for description. */
66
urls = [:]

ci/Jenkinsfile.ios

Lines changed: 36 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
#!/usr/bin/env groovy
2-
library '[email protected].29'
2+
library '[email protected].30'
33

44
/* Options section can't access functions in objects. */
55
def isPRBuild = utils.isPRBuild()
6-
def isNightlyBuild = utils.isNightlyBuild()
76

87
pipeline {
98

@@ -20,6 +19,16 @@ pipeline {
2019
description: 'Level of verbosity based on nimbus-build-system setup.',
2120
choices: ['0','1','2','3']
2221
)
22+
string(
23+
name: 'TESTFLIGHT_POLL_TIMEOUT',
24+
description: 'TestFlight build polling timeout in minutes.',
25+
defaultValue: '30'
26+
)
27+
string(
28+
name: 'TESTFLIGHT_POLL_INTERVAL',
29+
description: 'TestFlight build polling interval in seconds.',
30+
defaultValue: '30'
31+
)
2332
}
2433

2534
options {
@@ -65,8 +74,11 @@ pipeline {
6574
IPHONE_SDK = "iphoneos"
6675
ARCH = "x86_64"
6776
/* iOS app paths */
68-
STATUS_IOS_APP_ARTIFACT = "pkg/${utils.pkgFilename(ext: 'app.zip', arch: getArch(), version: env.VERSION, type: env.APP_TYPE)}"
77+
STATUS_IOS_APP_ARTIFACT = "pkg/${utils.pkgFilename(ext: 'ipa', arch: getArch(), version: env.VERSION, type: env.APP_TYPE)}"
6978
STATUS_IOS_APP = "${WORKSPACE}/mobile/bin/ios/qt6/Status.app"
79+
STATUS_IOS_IPA = "${WORKSPACE}/mobile/bin/ios/qt6/Status.ipa"
80+
TESTFLIGHT_POLL_TIMEOUT = "${params.TESTFLIGHT_POLL_TIMEOUT}"
81+
TESTFLIGHT_POLL_INTERVAL = "${params.TESTFLIGHT_POLL_INTERVAL}"
7082
}
7183

7284
stages {
@@ -91,25 +103,41 @@ pipeline {
91103

92104
stage('Build iOS App') {
93105
steps {
94-
sh 'make mobile-build'
106+
script {
107+
app.buildSignedIOS(target='mobile-build', verbose=params.VERBOSE)
108+
}
95109
}
96110
}
97111

98112
stage('Package iOS App') {
99113
steps {
100114
sh 'mkdir -p pkg'
101-
sh "cd mobile/bin/ios/qt6 && zip -r ${env.WORKSPACE}/${env.STATUS_IOS_APP_ARTIFACT} Status.app"
102-
sh "ls -la ${env.STATUS_IOS_APP_ARTIFACT}"
115+
sh "cp ${env.STATUS_IOS_IPA} ${env.STATUS_IOS_APP_ARTIFACT}"
116+
sh "ls -lh ${env.STATUS_IOS_APP_ARTIFACT}"
103117
}
104118
}
105119

106120
stage('Parallel Upload') {
107121
parallel {
108-
stage('Upload') {
122+
stage('Upload to TestFlight') {
123+
steps {
124+
script {
125+
def changelog = sh(script: './scripts/generate-changelog.sh', returnStdout: true).trim()
126+
127+
app.uploadToTestFlight(
128+
ipaPath=env.STATUS_IOS_APP_ARTIFACT,
129+
changelog=changelog,
130+
pollTimeout=env.TESTFLIGHT_POLL_TIMEOUT,
131+
pollInterval=env.TESTFLIGHT_POLL_INTERVAL
132+
)
133+
}
134+
}
135+
}
136+
stage('Upload to S3') {
109137
steps {
110138
script {
111139
env.PKG_URL = s5cmd.upload(env.STATUS_IOS_APP_ARTIFACT)
112-
jenkins.setBuildDesc(APP: env.PKG_URL)
140+
jenkins.setBuildDesc(IPA: env.PKG_URL)
113141
}
114142
}
115143
}

ci/Jenkinsfile.linux

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env groovy
2-
library '[email protected].29'
2+
library '[email protected].30'
33

44
/* Options section can't access functions in objects. */
55
def isPRBuild = utils.isPRBuild()

ci/Jenkinsfile.linux-nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env groovy
22

3-
library '[email protected].29'
3+
library '[email protected].30'
44

55
/* Options section can't access functions in objects. */
66
def isPRBuild = utils.isPRBuild()

ci/Jenkinsfile.macos

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env groovy
2-
library '[email protected].29'
2+
library '[email protected].30'
33

44
/* Options section can't access functions in objects. */
55
def isPRBuild = utils.isPRBuild()

ci/Jenkinsfile.qt-build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env groovy
2-
library '[email protected].29'
2+
library '[email protected].30'
33

44
pipeline {
55
agent {

ci/Jenkinsfile.tests-e2e

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env groovy
2-
library '[email protected].29'
2+
library '[email protected].30'
33

44
pipeline {
55
agent {

ci/Jenkinsfile.tests-e2e.windows

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env groovy
2-
library '[email protected].29'
2+
library '[email protected].30'
33

44
pipeline {
55

0 commit comments

Comments
 (0)