This topic describes how to create a Swift repository. This is required before publishing and installing Swift packages. There are three primary types of repositories:
Local repositories: Store and share first- and second-party packages with your organization
Remote repositories: Download packages from any remote location, including external package registries or other Artifactory instances
Note
Swift remote repositories are supported as private Swift registries, including Smart Remote repositories. There is currently no official public Swift registry. When a public Swift registry becomes available, it will be supported out of the box.
Virtual repositories: Aggregate remote and local repositories, enabling your organization to scale by providing a single URL that provides access to multiple repositories and types
For more information on JFrog repositories, see Repository Management Overview.
Prerequisite: You need Admin or Project Admin permissions in Artifactory to create a repository. If you don't have Admin permissions, the option will not be available.
To create a Swift repository:
In the Administration tab, click Repositories | Create a Repository.
Select the type of repository you want to create: local, remote, or virtual.
Select the Swift package type.
Configure the required fields for the repository:
For local repositories, in the Repository Key field, type a meaningful name for the repository. For example,
swift-local. For more information on local repositories and their settings, see Local Repositories.For remote repositories, verify the Repository URL and update as needed. For more information on remote repositories and their settings, see Remote Repositories.
Swift remote repositories can only connect to registries that use the Swift registry protocol. URLs like https://swiftpackageregistry.com are HTML catalogs that do not host any packages, but point to GitHub repositories that host packages.
For virtual repositories, select one or more local or remote repository types to include in the virtual repository. For more information on virtual repositories and their settings, see Virtual Repositories.
Click Create Repository. The repository is created and the Repositories window is displayed.