mysql - add status and refactor setup step
This commit is contained in:
@@ -9,25 +9,38 @@ dbUser=
|
|||||||
dbRemote=localhost
|
dbRemote=localhost
|
||||||
dbPass=
|
dbPass=
|
||||||
|
|
||||||
step_1_info() {
|
step_1_info() { echo "Status"; }
|
||||||
|
step_1_alias() { echo "status"; }
|
||||||
|
step_1() {
|
||||||
|
exe apt policy mariadb-server
|
||||||
|
}
|
||||||
|
|
||||||
|
step_5_info() { echo "Setup ubuntu $databaseName repository"; }
|
||||||
|
step_5_alias() { echo "setup"; }
|
||||||
|
step_5() {
|
||||||
|
exe apt install curl
|
||||||
|
exep "curl -sS https://downloads.mariadb.com/MariaDB/mariadb_repo_setup | sudo bash -s -- --skip-maxscale --skip-tools"
|
||||||
|
}
|
||||||
|
|
||||||
|
step_6_info() {
|
||||||
echo "Installation of ${databaseName} packages:"
|
echo "Installation of ${databaseName} packages:"
|
||||||
echoinfo "$databasePackages"
|
echoinfo "$databasePackages"
|
||||||
echoinfo "(Consider step \"latest\" first to setup official repository with the latest version)"
|
echoinfo "(Consider step \"setup\" first)"
|
||||||
}
|
}
|
||||||
step_1_alias() { echo install; }
|
step_6_alias() { echo install; }
|
||||||
step_1() {
|
step_6() {
|
||||||
exe apt update
|
exe apt update
|
||||||
exe apt install $databasePackages
|
exe apt install $databasePackages
|
||||||
endReturn -o $? "Error instaling $databaseName"
|
endReturn -o $? "Error instaling $databaseName"
|
||||||
}
|
}
|
||||||
|
|
||||||
step_2_info() { echo "Secure ${databaseName} installation"; }
|
step_7_info() { echo "Secure ${databaseName} installation"; }
|
||||||
step_2() {
|
step_7() {
|
||||||
exe mysql_secure_installation
|
exe mysql_secure_installation
|
||||||
}
|
}
|
||||||
|
|
||||||
step_3_info() { echo "${databaseName} configuration"; }
|
step_8_info() { echo "${databaseName} configuration"; }
|
||||||
step_3() {
|
step_8() {
|
||||||
addConf -c "$mariadbConfig" "$mariadbConfigLoc"
|
addConf -c "$mariadbConfig" "$mariadbConfigLoc"
|
||||||
|
|
||||||
echo -n "Restarting mysql ... "
|
echo -n "Restarting mysql ... "
|
||||||
@@ -46,13 +59,6 @@ table_definition_cache=1400
|
|||||||
|
|
||||||
#innodb_force_recovery=6"
|
#innodb_force_recovery=6"
|
||||||
|
|
||||||
step_8_info() { echo "Setup ubuntu $databaseName repository"; }
|
|
||||||
step_8_alias() { echo "latest"; }
|
|
||||||
step_8() {
|
|
||||||
exe apt install curl
|
|
||||||
exep "curl -sS https://downloads.mariadb.com/MariaDB/mariadb_repo_setup | sudo bash -s -- --skip-maxscale --skip-tools"
|
|
||||||
}
|
|
||||||
|
|
||||||
step_10_info() {
|
step_10_info() {
|
||||||
echo "Create mysql database without specific characterset"
|
echo "Create mysql database without specific characterset"
|
||||||
echoinfo " [OPTIONS]"
|
echoinfo " [OPTIONS]"
|
||||||
|
Reference in New Issue
Block a user