Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion scripts/proxy-common.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,13 @@ actions:
- cmd [proxy]: |-
mysql -h 127.0.0.1 -P3360 -uroot -e "DROP DATABASE IF EXISTS orchestrator;"
mysql -h 127.0.0.1 -P3360 -uroot -e "CREATE DATABASE IF NOT EXISTS orchestrator;"
mysql -h 127.0.0.1 -P3360 -uroot -e "GRANT ALL PRIVILEGES ON orchestrator.* TO 'admin'@'127.0.0.1' IDENTIFIED BY '${globals.ORCH_PASS}';"
major_version=$(rpm -qi mysql-community-server | grep Version | awk '{print $3}' | awk -F'.' '{print $1}');
if [ $major_version -ge 8 ]; then
mysql -h 127.0.0.1 -P3360 -uroot -e "ALTER USER 'admin'@'127.0.0.1' IDENTIFIED BY '${globals.ORCH_PASS}';"
else
mysql -h 127.0.0.1 -P3360 -uroot -e "SET PASSWORD FOR 'admin'@'127.0.0.1' = PASSWORD('${globals.ORCH_PASS}');"
fi
mysql -h 127.0.0.1 -P3360 -uroot -e "FLUSH PRIVILEGES;"
wget ${baseUrl}/configs/orchestrator.conf.json -O /etc/orchestrator.conf.json &>> /var/log/run.log
sed -i -e 's|orc_client_user|${globals.DB_USER}|g' /etc/orchestrator.conf.json
sed -i -e 's|orc_client_password|${globals.DB_PASS}|g' /etc/orchestrator.conf.json
Expand Down
2 changes: 1 addition & 1 deletion scripts/proxy-galera.jps
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ id: mysql-proxy-galera-cluster
name: Galera/XtraDB Cluster with ProxySQL
description: Galera/XtraDB Cluster

baseUrl: https://github.com/raw/dimkadt/mysql-cluster/v3.0.0
baseUrl: https://github.com/raw/jelastic-jps/mysql-cluster/stage-cluster

success: /texts/proxy-entrypoint.md

Expand Down
2 changes: 1 addition & 1 deletion scripts/proxy-master-slave.jps
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ id: mysql-proxy-master-slave-cluster
name: MySQL/MariaDB/Percona Database Cluster with ProxySQL
description: ProxySQL Load Balancer Entry Point

baseUrl: https://github.com/raw/dimkadt/mysql-cluster/v3.0.0
baseUrl: https://github.com/raw/jelastic-jps/mysql-cluster/stage-cluster

success: /texts/proxy-entrypoint.md

Expand Down