Create the Artifactory MySQL Database
Artifactory provides a script that will execute the SQL commands you need to create your MySQL database.
Artifactory provides a script that will execute the SQL commands you need to create your MySQL database. You can find the script in $JFROG_HOME/artifactory/app/misc/db/createdb/createdb_mysql.sql.
The default createdb.sql script is shown below. Note that:
- While MySQL database server is not case-sensitive by default, Artifactory is case-sensitive. Select a case-sensitive collation. In the default script "
utf8_bin"is specified. UTF8MB4 is not supported. We recommend that you adhere to the default "utf8_bin". - We recommend providing Artifactory with full privileges on the database, as shown in the default script.
CREATE DATABASE artdb CHARACTER SET utf8 COLLATE utf8_bin;
CREATE USER 'artifactory'@'%' IDENTIFIED BY 'password';
GRANT ALL on artdb.* TO 'artifactory'@'%';
FLUSH PRIVILEGES;Review the script and modify it as needed for your environment. Then run it to create the database.
Enable MySQL Connectivity from Remote Servers
The following example shows how to enable MySQL connectivity from remote servers. For your organization's best practices, consult with your security team.
To bind the IP addresses, edit the file /etc/mysql/mysql.conf.d/mysqld.cnf and modify the bind-address parameter. Change the default IP address to a comma-separated list of addresses. To bind to all available IP addresses, set the value to 0.0.0.0.
Restart the MySQL service to save the modifications.
Updated 5 days ago
