Skip to content

Commit bcb8805

Browse files
committed
Revert "[ios, ci] Use AdHoc entitlements for AdHoc builds"
This reverts commit 8c3bb93. We previously had to use separate AdHoc entitlements because the default mail-client entitlement couldn't be included due to the AdHoc provisioning profile not allowing it, causing the build to fail. After we contacted Apple, they made it so our AdHoc profiles now allow the mail-client entitlement, making this change unnecessary.
1 parent a20d134 commit bcb8805

File tree

5 files changed

+7
-80
lines changed

5 files changed

+7
-80
lines changed

app-ios/common.yml

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,25 +9,18 @@ settingGroups:
99
Release Development:
1010
PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]: "match AdHoc ${bundleIdPrefix}.$(PRODUCT_NAME)"
1111
Release Staging:
12-
# set default to AppStore. Its associated entitlement has default mail app capability.
1312
# Provisioning profile is used at two stages: archive and export.
1413
#
1514
# During archive the app is built and signed. Technically provisioning profile is not embedded at this stage
1615
# yet but since the app is signed at this step Xcode will check that the provisioning profile has correct
17-
# entitlements which could fail because ad-hoc provisioning profiles do not have default mail app capability.
16+
# entitlements.
1817
#
1918
# During export the provisioning profile will actually be used to package the app. This is the step where
2019
# Fastlane's match will instruct Xcode to use the right provisioning profile.
21-
#
22-
# For Ad-Hoc builds we will overwrite the entitlement in Fastfile (update_code_signing_settings). This will
23-
# update the xcodeproj file so that the archive can be generated without default mail app entitlement.
24-
#
25-
# For AppStore builds we do not overwrite the signing config so the values specified here will be applied
26-
# during archive step.
27-
PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]: "match AppStore $(PRODUCT_BUNDLE_IDENTIFIER)"
20+
PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]: "match AdHoc $(PRODUCT_BUNDLE_IDENTIFIER)"
2821
Release Production:
2922
CODE_SIGN_ENTITLEMENTS: "$(TARGET_NAME)/$(TARGET_NAME).entitlements"
30-
PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]: "match AppStore $(PRODUCT_BUNDLE_IDENTIFIER)"
23+
PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]: "match AdHoc $(PRODUCT_BUNDLE_IDENTIFIER)"
3124
extension:
3225
base:
3326
SKIP_INSTALL: "YES"

app-ios/fastlane/Fastfile

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -68,15 +68,6 @@ platform :ios do
6868

6969
clear_derived_data
7070

71-
# The default mail-client entitlement can't be included in the AdHoc entitlements because the AdHoc provisioning
72-
# profile doesn't allow it and will cause the build to fail.
73-
update_code_signing_settings(
74-
path: "tutanota.xcodeproj",
75-
targets: ["tutanota"],
76-
entitlements_file_path: "tutanota/tutanotaAdHoc.entitlements",
77-
build_configurations: ["Release Production"]
78-
)
79-
8071
ipa_name = "tutanota-" + get_version_number(target: "tutanota", xcodeproj: "tutanota.xcodeproj") + "-adhoc"
8172
build_app(
8273
scheme: "tuta prod",
@@ -138,15 +129,6 @@ platform :ios do
138129

139130
clear_derived_data
140131

141-
# The default mail-client entitlement can't be included in the AdHoc entitlements because the AdHoc provisioning
142-
# profile doesn't allow it and will cause the build to fail.
143-
update_code_signing_settings(
144-
path: "tutanota.xcodeproj",
145-
targets: ["tutanota"],
146-
entitlements_file_path: "tutanota/tutanotaAdHocStaging.entitlements",
147-
build_configurations: ["Release Staging"]
148-
)
149-
150132
build_app(
151133
scheme: "tuta staging",
152134
output_directory: "releases",

app-ios/tutanota/tutanotaAdHoc.entitlements

Lines changed: 0 additions & 20 deletions
This file was deleted.

app-ios/tutanota/tutanotaAdHocStaging.entitlements

Lines changed: 0 additions & 20 deletions
This file was deleted.

ci/Ios.Jenkinsfile

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -89,15 +89,11 @@ pipeline {
8989
buildWebapp("test")
9090
generateXCodeProjects()
9191
util.runFastlane("de.tutao.tutanota.test", "adhoc_staging")
92-
// Fastlane will overwrite code signing settings for adhoc so we regenerate the project
93-
// to make sure it is in correct state.
94-
generateXCodeProject("app-ios", "mail-project")
95-
util.runFastlane("de.tutao.tutanota.test", "build_mail_staging")
96-
9792
if (params.UPLOAD) {
93+
util.runFastlane("de.tutao.tutanota.test", "build_mail_staging")
9894
stash includes: "app-ios/releases/tutanota-${VERSION}-test.ipa", name: 'ipa-staging'
99-
stash includes: "app-ios/releases/tutanota-${VERSION}-adhoc-test.ipa", name: 'ipa-adhoc-staging'
10095
}
96+
stash includes: "app-ios/releases/tutanota-${VERSION}-adhoc-test.ipa", name: 'ipa-adhoc-staging'
10197
}
10298
}
10399
}
@@ -118,15 +114,11 @@ pipeline {
118114
buildWebapp("prod")
119115
generateXCodeProjects()
120116
util.runFastlane("de.tutao.tutanota", "adhoc_prod")
121-
// Fastlane will overwrite code signing settings for adhoc so we regenerate the project
122-
// to make sure it is in correct state.
123-
generateXCodeProject("app-ios", "mail-project")
124-
util.runFastlane("de.tutao.tutanota", "build_mail_prod")
125-
126117
if (params.UPLOAD) {
118+
util.runFastlane("de.tutao.tutanota", "build_mail_prod")
127119
stash includes: "app-ios/releases/tutanota-${VERSION}.ipa", name: 'ipa-production'
128-
stash includes: "app-ios/releases/tutanota-${VERSION}-adhoc.ipa", name: 'ipa-adhoc-production'
129120
}
121+
stash includes: "app-ios/releases/tutanota-${VERSION}-adhoc.ipa", name: 'ipa-adhoc-production'
130122
}
131123
}
132124
} // steps

0 commit comments

Comments
 (0)