Locate the Federated Base URL
To check whether the Federated repository has a Federated base URL, do the following:
- In the Administration tab, select Artifactory > Advanced > Config Descriptor.
- Search the configuration file for a Federation base URL entry:
The Config Descriptor can also be checked by sending a POST request using the relevant REST API. See Modifying Configuration Using the REST API.
Change the Base URL
If the Federation uses Federated base URLs, and these URLs are not changing, all the Administrator needs to do is change the base URL directly from the JFrog platform UI, as described below.
- In the Administration tab, select General > Settings.
- Enter a new custom base URL.
- Click Save.
It is also possible to change the custom base URL using the Update Custom URL Base REST API.
Change the Federated Base URL
If the Federation uses Federated base URLs and the URLs need to change, the Administrator makes the change using the Config Descriptor. See Locate the Federated Base URL for details.
Generate New Tokens
When the Federation members do not have Federated base URLs, or if the Federated base URLs have changed, the Administrator must generate a new pairing token and pair the source and target JPDs.
Make sure to perform this procedure on each remote Federation member.
- Generate a new token from the source JPD using the Create Pairing Token Platform REST API.
- Pair the target JPD to the source JPD using the new token with the Initiate Pairing Platform REST API.
- Replace the base URL (or Federated base URL) by executing the following POST request against the target JPD:
api/federation/replaceUrl
with the following body:
{ "oldBaseUrl": "http:/<old base URL>/artifactory", "newBaseUrl": "http://<new base URL>/artifactory" }
For more information, see Replace URL in the Artifactory REST API.
After Changing the Base URL
It is strongly recommended to test the functionality of the Federation after changing the base URL or Federated base URL. After verifying that the Federation members are successfully synchronized, the administrator can optionally revoke the obsolete keys.
- In the Administration tab, select Monitoring > Federation Status. If you see that the Federation is no longer in sync, there is a problem with the new configuration. See View Federation Sync Status for more information.
- [optional] After verifying that all Federation members have synchronized successfully with the updated base URL, revoke the obsolete key for each remote JPD using the Revoke Pairing REST API.
As a fallback, it is possible to change the base URL in a more aggressive way by canceling the Federation, changing the base URL, and then recreating the Federation. Please note this has a huge impact on the system since it requires creating each Federated repository again from scratch. For more information, see Working with Federated Repositories.