I am trying to run my Cordova app on the connected iPhone, but everytime I try to do cordova run
I am getting the following error
Check dependencies
No profiles for 'com.myapp.chat' were found: Xcode couldn't find a provisioning profile matching 'com.myapp.chat'. Code signing is required for product type 'Application' in SDK 'iOS 10.3'
I have created a build.json
file in the root directory of the project with the following contents
{
"ios": {
"debug": {
"developmentTeam": "some_id_here"
},
"release": {
"developmentTeam": "some_id_here",
"codeSignIdentity": "My App",
"packageType": "ad-hoc"
}
}
}
The ID of the profile is correct, I have downloaded it from the developer support page, the com.myapp.chat
package name is also registered on that provisioning profile.
I have XCode 8.3.2 installed, and I have logged in with my account in it in Preferences > Accounts, then I have clicked Download All Profiles.
EDIT: I am using Cordova CLI to build the app.
What am I doing wrong please?
To build your Cordova app to an iPhone follow these steps:
cordova add platform ios
, which will create the Xcode project file .xcworkspace
in your Cordova project directory under "platforms > ios".xcworkspace
file under "platforms > ios"Applications > Utilities > KeyChain Access
CertificateSigningRequest.certSigningRequest
file, by going to "Certificate Assistant > Request a Certificate From a Certificate Authority", and upload that to Apple Developers.Applications > Utilities > Terminal
sudo npm install -g cordova
(use sudo
)cordova <app_directory> <bundle_id> <app_name>
cordova gmail_app com.google.gmail Gmail
.cordova platform add ios
(which will create .xcodeproj
)Under "Identifiers" create a new "App Id" (click on the "+" icon), and set the "name" field with the same name as your Cordova app <app_name>
, and the bundle ID with the same as the Cordova <bundle_id>
.
Under "Provisioning Profiles" create a new "iOS Development" provisioning profile, with the name of your app <app_name>
and select the bundle id <bundle_id>
.
.xcworkspace
file under "platforms > ios" in your Cordova project.Once the project is open, click on the blue project icon to change the project settings.
Under "Signing" choose your Team...
build.json
file in the root directory of your Cordova project:cd <app_directory>; touch build.json;
build.json
file.{
"ios": {
"debug": {
"codeSignIdentity": "iPhone Developer",
"developmentTeam": "<Team ID>",
"packageType": "development"
},
"release": {
"codeSignIdentity": "iPhone Developer",
"developmentTeam": "<Team ID>",
"packageType": "app-store"
}
}
}
cordova build ios
, and it should build correctlyIf you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With