To resolve dependencies from CocoaPods repositories in Artifactory, connect the CocoaPods CDN to Artifactory.
Prerequisite: Before connecting your CocoaPods client to Artifactory, you must have an existing CocoaPods repository in Artifactory. For more information, see Create a CocoaPods Repository.
To connect the CocoaPods client to Artifactory:
Manually reindex your CocoaPods repository to create the required CDN index structure using one of the following methods:
REST API: Run the Calculate CocoaPods Index REST API.
Web UI: In the Platform module, under Artifactory | Artifacts, right-click the repository name and select Recalculate Index.
Add the following authentication snippet to your
.netrcfile:machine [JFrogPlatformURL] login <USERNAME> password <AUTH>Where:
[JFrogPlatformURL]: Your organization's Artifactory hostname<USERNAME>: Your Artifactory username<AUTH>: Your Artifactory identity token
For example:
machine company.jfrog.io login jeffry password 51HnvD0A1g2q3n4b5F6g7H8j9K0l1m2N3o4P5q6R7s8T9u0V1w2X3y4Run the following command to add an Artifactory CDN repository to your CocoaPods client:
pod repo add-cdn <REPO_NAME> "https://[JFrogPlatformURL]/artifactory/api/pods/<REPO_NAME>"Where:
<REPO_NAME>: The name of your CocoaPods repository in Artifactory[JFrogPlatformURL]: Your organization's Artifactory URL
For example:
pod repo add-cdn cocoapods-local "https://company.jfrog.io/artifactory/api/pods/cocoapods-local"
Once this configuration is complete, you can deploy and resolve pods in Artifactory using the CocoaPods CLI.
Note
You can also use JFrog Set me up to copy the snippet populated with your token and environment. For more information, see Use Artifactory Set Me Up for Configuring Package Manager Clients.
Next steps: