Skip to content

Commit

Permalink
fix(cli): iOS code signing failing on CI (#10854)
Browse files Browse the repository at this point in the history
Looks like Apple cannot handle development profile automatic provisioning well

With this change we now skip code signing for build() and archive(), and let the export() function handle signing

see fastlane/fastlane#19973 (comment) for more information
  • Loading branch information
lucasfernog authored Sep 1, 2024
1 parent 82b084e commit 6faa032
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 9 deletions.
6 changes: 6 additions & 0 deletions .changes/fix-ios-automatic-signing-ci.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"tauri-cli": patch:bug
"@tauri-apps/cli": patch:bug
---

Fixes iOS code signing failing on CI due to a missing development certificate.
6 changes: 3 additions & 3 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions crates/tauri-cli/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "tauri-cli"
version = "2.0.0-rc.9"
version = "2.0.0-rc.8"
authors = ["Tauri Programme within The Commons Conservancy"]
edition = "2021"
rust-version = "1.71"
Expand Down Expand Up @@ -36,7 +36,7 @@ name = "cargo-tauri"
path = "src/main.rs"

[target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"openbsd\", target_os = \"netbsd\", target_os = \"windows\", target_os = \"macos\"))".dependencies]
cargo-mobile2 = { version = "0.16", default-features = false }
cargo-mobile2 = { version = "0.17", default-features = false }

[dependencies]
jsonrpsee = { version = "0.24", features = ["server"] }
Expand All @@ -47,7 +47,7 @@ sublime_fuzzy = "0.7"
clap_complete = "4"
clap = { version = "4.5", features = ["derive", "env"] }
anyhow = "1.0"
tauri-bundler = { version = "2.0.1-rc.7", default-features = false, path = "../tauri-bundler" }
tauri-bundler = { version = "2.0.1-rc.6", default-features = false, path = "../tauri-bundler" }
colored = "2.1"
serde = { version = "1.0", features = ["derive"] }
serde_json = { version = "1.0", features = ["preserve_order"] }
Expand Down
15 changes: 12 additions & 3 deletions crates/tauri-cli/src/mobile/ios/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ use anyhow::Context;
use cargo_mobile2::{
apple::{
config::Config as AppleConfig,
target::{BuildConfig, ExportConfig, Target},
target::{ArchiveConfig, BuildConfig, ExportConfig, Target},
},
env::Env,
opts::{NoiseLevel, Profile},
Expand Down Expand Up @@ -301,7 +301,9 @@ fn run_build(

let credentials = auth_credentials_from_env()?;

let mut build_config = BuildConfig::new().allow_provisioning_updates();
let mut build_config = BuildConfig::new()
.allow_provisioning_updates()
.skip_codesign();
if let Some(credentials) = &credentials {
build_config = build_config.authentication_credentials(credentials.clone());
}
Expand All @@ -314,7 +316,14 @@ fn run_build(
build_config,
)?;

target.archive(config, env, noise_level, profile, Some(app_version))?;
target.archive(
config,
env,
noise_level,
profile,
Some(app_version),
ArchiveConfig::new().skip_codesign(),
)?;

let mut export_config = ExportConfig::new().allow_provisioning_updates();
if let Some(credentials) = credentials {
Expand Down

0 comments on commit 6faa032

Please sign in to comment.