How to copy Artifactory configurations from one instance to another

In order to make the migration of configuration files from one Artifactory instance to another, we recommend temporarily disabling the master key encryption using the instruction below, since users' private keys are encrypted and cannot be read by another Artifactory instance without the original key (the master key certificate file).

<STEP 1: Deactivate Master Key Encryption>

Description: Removes the current master key and deactivates master key encryption.
Since: 3.2.2
Notes: This is an advanced feature intended for administrators
Security: Requires a valid admin user
Usage: POST /api/system/decrypt
Produces: text/plain
Sample Usage:

POST /api/system/decrypt
 
DONE

 

e.g. curl -uadmin:password -XPOST http://mill.jfrog.info:12033/artifactory/api/system/decrypt

 

<STEP 2: GET Security Configuration>

Description: Retrieve the security configuration (security.xml).
Since: 2.2.0
Notes: This is an advanced feature - make sure the new configuration is really what you wanted before saving.
Security: Requires a valid admin user
Usage: GET /api/system/security
Produces: application/xml
Sample Output:

GET /api/system/security
 
<security.xml/>

e.g. curl -uadmin:password http://mill.jfrog.info:12033/artifactory/api/system/security -o security.xml
 

<STEP 3: GET General Configuration>

Description: Get the general configuration (artifactory.config.xml).
Since: 2.2.0
Security: Requires a valid admin user
Usage: GET /api/system/configuration
Produces: application/xml
Sample Output:

GET /api/system/configuration
 
<artifactory.config.xml/>

e.g. curl -uadmin:password http://mill.jfrog.info:12033/artifactory/api/system/configuration -o artifactory.config.xml

<STEP 4: Copy the files over to new artifactory instance>
1. Save both files to primary node/etc/ as artifactory.config.bootstrap.xml and security.import.xml
2. chown artifactory:artifactory both files
3. Restart each Artifactory node

<Step 5: Verification>
Verify that the passwords and API keys used in the original Artifactory instance works in the new instance