mirror of
https://github.com/zabbix/zabbix-docker.git
synced 2024-11-22 07:43:47 +01:00
Updated MySQL from utf8 to utf8mb4
This commit is contained in:
parent
0702033093
commit
96b02e7c5f
@ -270,7 +270,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -359,6 +359,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
||||||
|
@ -268,7 +268,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -357,6 +357,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
||||||
|
@ -268,7 +268,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -357,6 +357,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
||||||
|
@ -269,7 +269,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -358,6 +358,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
||||||
|
@ -267,7 +267,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -356,6 +356,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
update_config_var $ZBX_CONFIG "DBSocket" "${DB_SERVER_SOCKET}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
update_config_var $ZBX_CONFIG "ProxyLocalBuffer" "${ZBX_PROXYLOCALBUFFER}"
|
||||||
|
@ -265,7 +265,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -340,6 +340,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -262,7 +262,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -337,6 +337,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -262,7 +262,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -337,6 +337,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -262,7 +262,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -337,6 +337,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -262,7 +262,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
@ -337,6 +337,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -375,6 +375,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -375,6 +375,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -375,6 +375,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -375,6 +375,8 @@ update_zbx_config() {
|
|||||||
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
update_config_var $ZBX_CONFIG "DBPassword" "${DB_SERVER_ZBX_PASS}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
update_config_var $ZBX_CONFIG "AllowUnsupportedDBVersions" "${ZBX_ALLOWUNSUPPORTEDDBVERSIONS}"
|
||||||
|
|
||||||
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
update_config_var $ZBX_CONFIG "StartReportWriters" "${ZBX_STARTREPORTWRITERS}"
|
||||||
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
: ${ZBX_WEBSERVICEURL:="http://zabbix-web-service:10053/report"}
|
||||||
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
update_config_var $ZBX_CONFIG "WebServiceURL" "${ZBX_WEBSERVICEURL}"
|
||||||
|
@ -184,7 +184,7 @@ configure_db_mysql() {
|
|||||||
|
|
||||||
nohup $MYSQLD --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin \
|
nohup $MYSQLD --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin \
|
||||||
--log-output=none --pid-file=/var/lib/mysql/mysqld.pid \
|
--log-output=none --pid-file=/var/lib/mysql/mysqld.pid \
|
||||||
--port=3306 --character-set-server=utf8 --collation-server=utf8_bin $mysql_user &
|
--port=3306 --character-set-server=utf8mb4 --collation-server=utf8mb4_bin $mysql_user &
|
||||||
}
|
}
|
||||||
|
|
||||||
prepare_system() {
|
prepare_system() {
|
||||||
@ -314,7 +314,7 @@ create_db_database_mysql() {
|
|||||||
|
|
||||||
if [ -z ${DB_EXISTS} ]; then
|
if [ -z ${DB_EXISTS} ]; then
|
||||||
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
echo "** Database '${DB_SERVER_DBNAME}' does not exist. Creating..."
|
||||||
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8 COLLATE utf8_bin" 1>/dev/null
|
mysql_query "CREATE DATABASE ${DB_SERVER_DBNAME} CHARACTER SET utf8mb4 COLLATE utf8mb4_bin" 1>/dev/null
|
||||||
# better solution?
|
# better solution?
|
||||||
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
mysql_query "GRANT ALL PRIVILEGES ON $DB_SERVER_DBNAME. * TO '${DB_SERVER_ZBX_USER}'@'%'" 1>/dev/null
|
||||||
else
|
else
|
||||||
|
@ -415,8 +415,8 @@ services:
|
|||||||
image: mysql:8.0
|
image: mysql:8.0
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
# - --require-secure-transport
|
# - --require-secure-transport
|
||||||
# - --ssl-ca=/run/secrets/root-ca.pem
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
||||||
|
@ -511,8 +511,8 @@ services:
|
|||||||
image: mysql:8.0
|
image: mysql:8.0
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
# - --require-secure-transport
|
# - --require-secure-transport
|
||||||
# - --ssl-ca=/run/secrets/root-ca.pem
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
||||||
|
@ -413,8 +413,8 @@ services:
|
|||||||
- all
|
- all
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
volumes:
|
volumes:
|
||||||
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
||||||
|
@ -520,8 +520,8 @@ services:
|
|||||||
- all
|
- all
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
volumes:
|
volumes:
|
||||||
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
||||||
|
@ -415,8 +415,8 @@ services:
|
|||||||
image: mysql:8.0
|
image: mysql:8.0
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
# - --require-secure-transport
|
# - --require-secure-transport
|
||||||
# - --ssl-ca=/run/secrets/root-ca.pem
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
||||||
|
@ -509,8 +509,8 @@ services:
|
|||||||
image: mysql:8.0
|
image: mysql:8.0
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
# - --require-secure-transport
|
# - --require-secure-transport
|
||||||
# - --ssl-ca=/run/secrets/root-ca.pem
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
||||||
|
@ -413,8 +413,8 @@ services:
|
|||||||
- all
|
- all
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
volumes:
|
volumes:
|
||||||
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
||||||
|
@ -520,8 +520,8 @@ services:
|
|||||||
- all
|
- all
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
volumes:
|
volumes:
|
||||||
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
||||||
|
@ -415,8 +415,8 @@ services:
|
|||||||
image: mysql:8.0
|
image: mysql:8.0
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
# - --require-secure-transport
|
# - --require-secure-transport
|
||||||
# - --ssl-ca=/run/secrets/root-ca.pem
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
||||||
|
@ -509,8 +509,8 @@ services:
|
|||||||
image: mysql:8.0
|
image: mysql:8.0
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
# - --require-secure-transport
|
# - --require-secure-transport
|
||||||
# - --ssl-ca=/run/secrets/root-ca.pem
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
||||||
|
@ -413,8 +413,8 @@ services:
|
|||||||
- all
|
- all
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
volumes:
|
volumes:
|
||||||
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
||||||
|
@ -520,8 +520,8 @@ services:
|
|||||||
- all
|
- all
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
volumes:
|
volumes:
|
||||||
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
||||||
|
@ -407,8 +407,8 @@ services:
|
|||||||
image: mysql:8.0
|
image: mysql:8.0
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
# - --require-secure-transport
|
# - --require-secure-transport
|
||||||
# - --ssl-ca=/run/secrets/root-ca.pem
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
||||||
|
@ -503,8 +503,8 @@ services:
|
|||||||
image: mysql:8.0
|
image: mysql:8.0
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
# - --require-secure-transport
|
# - --require-secure-transport
|
||||||
# - --ssl-ca=/run/secrets/root-ca.pem
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
||||||
|
@ -407,8 +407,8 @@ services:
|
|||||||
- all
|
- all
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
volumes:
|
volumes:
|
||||||
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
||||||
|
@ -514,8 +514,8 @@ services:
|
|||||||
- all
|
- all
|
||||||
command:
|
command:
|
||||||
- mysqld
|
- mysqld
|
||||||
- --character-set-server=utf8
|
- --character-set-server=utf8mb4
|
||||||
- --collation-server=utf8_bin
|
- --collation-server=utf8mb4_bin
|
||||||
- --default-authentication-plugin=mysql_native_password
|
- --default-authentication-plugin=mysql_native_password
|
||||||
volumes:
|
volumes:
|
||||||
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
- ./zbx_env/var/lib/mysql:/var/lib/mysql:rw
|
||||||
|
Loading…
Reference in New Issue
Block a user