Steps to install

ARTIFACTORY: Installation Quick Start Guide - Docker-compose

AuthorFullName__c
Ino Choi
articleNumber
000005198
ft:sourceType
Salesforce
FirstPublishedDate
2022-01-13T19:31:41Z
lastModifiedDate
2024-03-13T09:49:24Z
VersionNumber
15

1. Extract the jfrog-artifactory-pro-<version>-compose.tar.gz file and go to the extracted folder.

$ tar -xvf jfrog-artifactory-pro-<version>-compose.tar.gz
$ cd artifactory-pro-<version>

2. Run the interactive script to set up Artifactory.

$ ./config.sh

3. It is recommended to define the Artifactory home directory into a directory that gives run and execute permissions to all users such as /opt.

Installation Directory (Default: /root/.jfrog/artifactory): /opt/jfrog/artifactory

4. Specify the IP address of the Artifactory machine.

For IPv6 address, enclose value within square brackets as follows : [<ipv6_address>]
Please specify the IP address of this machine (Default: <IP_ADDRESS>):

5. If you’re setting up an HA cluster and adding this machine to an existing Artifactory instance, select “y”, otherwise select “N”.

Are you adding an additional node to an existing product cluster? [y/N]: N

6. As we will use the external database we have configured, select “N” and select the database.

The installer can install a PostgreSQL database, or you can connect to an existing compatible PostgreSQL database
(https://service.jfrog.org/installer/System+Requirements#SystemRequirements-RequirementsMatrix)
If you are upgrading from an existing installation, select N if you have externalized PostgreSQL, select Y if not.
Do you want to install PostgreSQL? [Y/n]: N

Provide the type of your external database that you want to connect to.
Note : If you choose derby, it will be considered as an internal database and no further details will be asked
Enter database type, supported values [ postgresql mssql mariadb mysql oracle derby ]: postgresql

7. Provide the URL, username, and password.

Provide the database connection details
PostgreSQL url. Example: [jdbc:postgresql://<IP_ADDRESS>:<PORT>/artifactory]: postgresql://<IP_ADDRESS>:5432/artifactory

Database username (If your existing connection URL already includes the username, leave this empty): artifactory

Database password (If your existing connection URL already includes the password, leave this empty):

Database connection successful

8. Setup is complete and you can start Artifactory using the provided Docker-Compose command.

start:               docker-compose -p rt up -d
stop:                docker-compose -p rt down

9. Check that artifactory starts up by checking the logs for the following message:
 

$ docker logs -f artifactory
2021-09-20T20:44:34.610Z [jfrou] [INFO ] [30a6b3f102dc9b52] [local_topology.go:270         ] [main                ] - 
###############################################################
###   All services started successfully in 86.544 seconds   ###
###############################################################

10.  Once Artifactory comes up, the UI should be accessible at port 8082. Check that Artifactory is in HA mode by running the following REST API and look in the addon array for “ha”:

$ curl localhost:8082/artifactory/api/system/version -u admin:password
{
  "version" : "7.25.7",
  "revision" : "72507900",
  "addons" : [ "ha",...

11. To install additional nodes, follow the installation steps above.
 a. For the step asking about adding the machine to an existing Artifactory instance, select “y”

Are you adding an additional node to an existing product cluster? [y/N]: y
12. For a new node to join a cluster, the nodes must connect to the same database and have the same Master Key.

a) Copy the master.key from the first node to the additional nodes located at $JFROG_HOME/artifactory/var/etc/security/master.key.If you would like to generate your own key ahead of time, you can follow the guide here to do so

b) Start the additional nodes.

c) Check the Artifactory log.

$ docker-compose -p rt logs

(*) For Docker installations, verify that the host's ID “shared.node.id” and IP “shared.node.ip” are added to the system.yaml. If these are not manually added, they are automatically resolved as the container's hostname and IP, meaning other nodes and services will not be able to reach this instance. 
 

shared:
  extraJavaOpts: "-Xms512m -Xmx4g"
  node:
    id: "MyNodeID"
    ip: "10.1.2.3"

Make sure to keep your YAML spacing consistent! We recommend either 2 or 4 spaces indentation, but ensure that it is consistent throughout.