


#Check file ansible]# ansible-playbook -C mysql.yml Custom Installation subsequent according to the actual situation by modifying vars / main.yml relevant parameters for custom installation. In addition to compiling and installing mysql, this script also initializes the mysql database, makes corresponding modifications to the configuration file my.cnf whose parameters have been left blank, sets a password, and starts the database.ĥ. The directory structure of the playbook ansible]# cd /etc/ansible/ ansible]# mkdir -p roles/mysql_install/ install_mysql From mysql.yml: mysql install Call the playbook Through the Install.yml tasks, the mysql install.sh template is named to install mysql in the installation directory specified in the variable.

Using copy.yml in tasks to pass source code files to a remote server’s source code storage directory.ģ. Configure variables in vars via main.yml, primarily the storage directory for source code and the installation directory
