Skip to content

Commit 76ac84e

Browse files
authored
feat(linux): use mysql 8.4 (#293)
* feat(linux): use mysql 8.4 * Update MySQL version selection in setup script * Disable MySQL module for RHEL before installation * Update MySQL RPM URL for RHEL based on OS version * Remove MySQL module disable command for RHEL * Disable weak dependencies for RPM installation
1 parent 32c3475 commit 76ac84e

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

templates/linux/setup.sh

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ update() {
162162
}
163163

164164
install_rpm() {
165-
dnf install -y "$@"
165+
dnf install -y --setopt install_weak_deps=False "$@"
166166
}
167167

168168
remove_rpm() {
@@ -498,16 +498,12 @@ install_mysql() {
498498
user_password="$(generate_password)"
499499

500500
if [[ $os_type == 'rhel' ]]; then
501-
if [[ $os_version == '8' ]]; then
502-
install_rpm https://dev.mysql.com/get/mysql80-community-release-el8-9.noarch.rpm
503-
dnf -y module disable mysql
504-
else
505-
install_rpm https://dev.mysql.com/get/mysql80-community-release-el9-5.noarch.rpm
506-
fi
501+
install_rpm "https://dev.mysql.com/get/mysql84-community-release-el${os_version}-2.noarch.rpm"
507502
fi
508503

509504
if [[ $os_type == 'debian' ]] || [[ $os_type == 'ubuntu' ]]; then
510505
install wget debconf-utils lsb-release gnupg2
506+
debconf-set-selections <<< "mysql-apt-config mysql-apt-config/select-server select mysql-8.4-lts"
511507
debconf-set-selections <<< "mysql-apt-config mysql-apt-config/select-product select Ok"
512508
debconf-set-selections <<< "mysql-server mysql-server/root_password password ${root_password}"
513509
debconf-set-selections <<< "mysql-server mysql-server/root_password_again password ${root_password}"

0 commit comments

Comments
 (0)