Skip to content

Commit

Permalink
chore: reformat docs to look good with mddocs
Browse files Browse the repository at this point in the history
  • Loading branch information
sudharsan-selvaraj committed Aug 3, 2024
1 parent 72a15b5 commit 585bef3
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 28 deletions.
70 changes: 43 additions & 27 deletions documentation/docs/ios-signing.md
Original file line number Diff line number Diff line change
@@ -1,59 +1,75 @@
---
title: Webdriver Agent Signing
title: WebdriverAgent Signing with Xcode
hide:
- navigation
---

The Appium device farm now allows you to manage devices readl IOS devices on non-Mac systems, including Raspberry Pi. To optimize its functionality, you need to re-sign the WebDriver agent with your provisioning profile and upload it to the device farm. The device farm will handle all the internal configuration. Below are the steps needed to sign the WebDriver agent.

## Prerequisite:
## Prerequisite

1. A Mac machine with Xcode and Xcode command line tools installed
2. A valid Apple account (with or without a developer program subscription)
3. The iOS Resigner app for re-signing the WDA IPA, which you can download from [iOS Resigner GitHub](https://github.com/DanTheMan827/ios-app-signer/releases)

## Download Webdriver Agent .ipa
## Download WebdriverAgent app

The Appium device farm has already built a WDA IPA file for you to download and use for signing. You can obtain the IPA file from the [Appium Device Farm GitHub repository](https://github.com/AppiumTestDistribution/appium-device-farm/raw/main/WDA.ipa). Save the file to your Mac machine.

## Creating Provisioning profile

1. Open Xcode and sign in with your Apple ID.
![xcode](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step1-xcode-settings.png)
Open Xcode and sign in with your Apple ID.

2. click the `+` icon to add a new account
![Xcode create account](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step2-add-account.png)
![xcode](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step1-xcode-settings.png)

3. Select `Apple ID` from the options and click `Continue`
![Xcode sign in](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step3-add-account-apple-id.png)
click the `+` icon to add a new account

4. Log in with your existing Apple ID or click `Create Apple ID` to create a new Apple account.
![Xcode account](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step4-login-email.png)
![Xcode create account](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step2-add-account.png)

5. Once logged in successfully, you should see your account added to the account list.
![Xcode account list](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step5-after-login.png)
Select `Apple ID` from the options and click `Continue`

6. Now, create the provisioning profile for re-signing the WDA. Open `Xcode > File > New > Project`.
![Xcode create project](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step6-create-project.png)
![Xcode sign in](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step3-add-account-apple-id.png)

7. Select any app type from the list. Choosing `App` is recommended for simplicity.
![Xcode select app](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step7-selcect-app-type.png)
Log in with your existing Apple ID or click `Create Apple ID` to create a new Apple account.

8. Enter a Project Name and a valid `Organization Identifier`. It can be any value, but ensure it is unique. Select the Apple account you logged in with from the Team dropdown. After entering the details, click `Next` and choose a folder to create the project.
![Xcode org id](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step8-enter-project-details.png)
![Xcode account](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step4-login-email.png)

9. Once the project is created, click on the `Project Name` in the left pane and select the `Signing & Capabilities` tab. You should see `Xcode Managed Profile` listed under Provisioning Profile.
![xcode signing](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step9-post-project-creation.png)
Once logged in successfully, you should see your account added to the account list.

10. You can also check if the provisioning profile is created in the `~/Library/MobileDevice/Provisioning Profiles directory`. Once the provisioning profile is present, you have successfully created it and can now use it to sign the WDA file.
![Xcode account list](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step5-after-login.png)

Now, create the provisioning profile for re-signing the WDA. Open `Xcode > File > New > Project`.

![Xcode create project](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step6-create-project.png)

Select any app type from the list. Choosing `App` is recommended for simplicity.

![Xcode select app](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step7-selcect-app-type.png)

Enter a Project Name and a valid `Organization Identifier`. It can be any value, but ensure it is unique. Select the Apple account you logged in with from the Team dropdown. After entering the details, click `Next` and choose a folder to create the project.

![Xcode org id](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step8-enter-project-details.png)

Once the project is created, click on the `Project Name` in the left pane and select the `Signing & Capabilities` tab. You should see `Xcode Managed Profile` listed under Provisioning Profile.

![xcode signing](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step9-post-project-creation.png)

You can also check if the provisioning profile is created in the `~/Library/MobileDevice/Provisioning Profiles directory`. Once the provisioning profile is present, you have successfully created it and can now use it to sign the WDA file.

To re-sign the IPA, open the `iOS Resigner app` that you previously downloaded. Select the WDA IPA file that you downloaded as the input file. Choose your Apple account from the `Signing Certificate` dropdown. In the `Provisioning Profile` dropdown, select the provisioning profile you created earlier.

11. To re-sign the IPA, open the `iOS Resigner app` that you previously downloaded. Select the WDA IPA file that you downloaded as the input file. Choose your Apple account from the `Signing Certificate` dropdown. In the `Provisioning Profile` dropdown, select the provisioning profile you created earlier.
![Ios resign](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step10-ios-resign-1.png)

12. After entering all the details, click "Start" and select a folder to save the resigned IPA file. Ensure you save it with the name `wda-resign.ipa` and click "Save." This will create a new file in the output directory.
After entering all the details, click "Start" and select a folder to save the resigned IPA file. Ensure you save it with the name `wda-resign.ipa` and click "Save." This will create a new file in the output directory.

![ios wda sign](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step11-ios-resign-save.png)

13. Once the WebDriver agent is successfully re-signed, it needs to be uploaded to the Appium device farm. Open the device farm using the server URL in your browser, switch to the `Apps` section, and click the `Upload Apps` button.
## Uploading signed WDA in device farm

Once the WebDriver agent is successfully re-signed, it needs to be uploaded to the Appium device farm. Open the device farm using the server URL in your browser, switch to the `Apps` section, and click the `Upload Apps` button.

![df app upload](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step12-df-uplaod-app.png)

14. Choose the resigned IPA named `wda-resign.ipa` and click "Upload." You should see a success popup indicating the file upload was successful. That's it! You are now ready to use real iOS devices with the device farm.
![df upload success](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step13-df-uplaod-done.png)
Choose the resigned IPA named `wda-resign.ipa` and click "Upload." You should see a success popup indicating the file upload was successful. That's it! You are now ready to use real iOS devices with the device farm.

![df upload success](https://raw.githubusercontent.com/AppiumTestDistribution/appium-device-farm/main/documentation/docs/assets/images/wda-signing/step13-df-uplaod-done.png)
3 changes: 2 additions & 1 deletion documentation/mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ markdown_extensions:
custom_fences:
- name: mermaid
class: mermaid
format: ""
format: ''
- pymdownx.superfences:
custom_fences:
- name: mermaid
Expand All @@ -50,4 +50,5 @@ nav:
- Reference:
- server-args.md
- capabilities.md
- ios-signing.md
- reference/commands/sample.md

0 comments on commit 585bef3

Please sign in to comment.