Configuration
To create a Smart Remote Repository, set the repository URL to point to a repository in another instance of Artifactory.
Repository URL must be prefixed with api/<type>
To accommodate different packaging format clients, for several repository types, when accessing the repository through Artifactory, the repository URL must be prefixed with api/<type> in the path.
For example,
http://<JFrog URL>/artifactory/api/<package type>/<repository key>
Or, if you are using Artifactory Cloud the URL would be:
https://<server name>.jfrog.io/artifactory/api/<package type>/<repository key>
The prefix is required for the following repository types:
Type | Prefix |
---|---|
Bower | api/bower |
Chef | api/chef |
CocoaPods | api/pods |
Conan | api/conan |
Docker | api/docker |
Go | api/go |
NuGet | api/nuget |
Npm | api/npm |
PHP Composer | api/composer |
Puppet | api/puppet |
PyPI | See PyPI Settings |
RubyGems | api/gems |
PyPI Settings
PyPi repositories also require a registry URL which depends on whether the target is a local, remote or virtual repository on the target Artifactory instance. For example,
For a local repository:
URL: http://<JFROG_URL>/artifactory/pypi-local/
Registry URL: http://<JFROG_URL>/artifactory/api/pypi/pypi-local/
For a remote repository:
URL: http://<JFROG_URL>/artifactory/pypi-remote/
Registry URL: h
ttp://<JFROG_URL>/artifactory/api/pypi/pypi-remote/
Once you have finished entering the URL and move to another field, Artifactory automatically detects that the remote URL is on another instance of Artifactory and displays a dialog where you can configure the behavior of your smart remote repository.
Note also that the package type icon is overlaid with an Artifactory logo to indicate a smart remote repository.
Report Statistics | If set, Artifactory will notify the remote instance whenever an artifact in the Smart Remote Repository is downloaded locally so that it can update its download counter. Note that if this option is not set, there may be a discrepancy between the number of artifacts reported to have been downloaded in the different Artifactory instances of the proxy chain. |
Sync Properties | If set, properties for artifacts that have been cached in this repository will be updated if they are modified in the artifact hosted at the remote Artifactory instance. The trigger to synchronize the properties is download of the artifact from the remote repository cache of the local Artifactory instance. |
List Remote Folder Items | If set, enables Remote List Browsing. |
Source Absence Detection | If set, Artifactory displays an indication on cached items if they have been deleted from the corresponding repository in the remote Artifactory instance. |
You can modify these settings at any time from the Edit Repository screen.
Smart Remote NuGet Repositories
When configuring a Smart Remote NuGet Repository, make sure to set Nuget Download Context Path to Download
and NuGet Feed Context Path should remain blank.
Remote List Browsing
When List Remote Folder Items is checked for a repository, Artifactory lets you navigate the contents of the repository at the remote Artifactory instance, for all package types, even if the artifacts have not been cached in the repository defined in your instance of Artifactory.
REST API
For a repository to be identified as a Smart Remote Repository, you need to set the “enabled” flag to true under “contentSynchronisation” (under Repository Configuration JSON).