diff --git a/.env_srv b/.env_srv index 318cf0b5c..d75615f5e 100644 --- a/.env_srv +++ b/.env_srv @@ -1,6 +1,6 @@ # ZBX_LISTENIP= -# ZBX_HISTORYSTORAGEURL= # Available since 3.4.0 -# ZBX_HISTORYSTORAGETYPES=uint,dbl,str,log,text # Available since 3.4.0 +# ZBX_HISTORYSTORAGEURL=http://elasticsearch:9200/ # Available since 3.4.5 +# ZBX_HISTORYSTORAGETYPES=uint,dbl,str,log,text # Available since 3.4.5 # ZBX_DEBUGLEVEL=3 # ZBX_STARTPOLLERS=5 # ZBX_IPMIPOLLERS=0 diff --git a/.env_web b/.env_web index 0b15d6d85..84302ce04 100644 --- a/.env_web +++ b/.env_web @@ -1,6 +1,8 @@ # ZBX_SERVER_HOST=zabbix-server # ZBX_SERVER_PORT=10051 ZBX_SERVER_NAME=Composed installation +# ZBX_HISTORYSTORAGEURL=http://elasticsearch:9200/ # Available since 3.4.5 +# ZBX_HISTORYSTORAGETYPES=['uint', 'dbl', 'str', 'text', 'log'] # Available since 3.4.5 # ZBX_MAXEXECUTIONTIME=600 # ZBX_MEMORYLIMIT=128M # ZBX_POSTMAXSIZE=16M diff --git a/agent/alpine/docker-entrypoint.sh b/agent/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/agent/alpine/docker-entrypoint.sh +++ b/agent/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/agent/centos/docker-entrypoint.sh b/agent/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/agent/centos/docker-entrypoint.sh +++ b/agent/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/agent/ubuntu/docker-entrypoint.sh b/agent/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/agent/ubuntu/docker-entrypoint.sh +++ b/agent/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/docker-compose_v3_alpine_mysql_latest.yaml b/docker-compose_v3_alpine_mysql_latest.yaml index fc67efcba..1e6e7d72d 100644 --- a/docker-compose_v3_alpine_mysql_latest.yaml +++ b/docker-compose_v3_alpine_mysql_latest.yaml @@ -382,6 +382,16 @@ services: volumes: - ./zbx_env/var/lib/mysql:/var/lib/mysql:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_alpine_mysql_local.yaml b/docker-compose_v3_alpine_mysql_local.yaml index 2fe3571b9..d8584af44 100644 --- a/docker-compose_v3_alpine_mysql_local.yaml +++ b/docker-compose_v3_alpine_mysql_local.yaml @@ -414,6 +414,16 @@ services: volumes: - ./zbx_env/var/lib/mysql:/var/lib/mysql:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_alpine_pgsql_latest.yaml b/docker-compose_v3_alpine_pgsql_latest.yaml index 9e2090cde..bbaef3695 100644 --- a/docker-compose_v3_alpine_pgsql_latest.yaml +++ b/docker-compose_v3_alpine_pgsql_latest.yaml @@ -402,6 +402,16 @@ services: volumes: - ./zbx_env/var/lib/postgresql/data:/var/lib/postgresql/data:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_alpine_pgsql_local.yaml b/docker-compose_v3_alpine_pgsql_local.yaml index b16737e4a..70c62c268 100644 --- a/docker-compose_v3_alpine_pgsql_local.yaml +++ b/docker-compose_v3_alpine_pgsql_local.yaml @@ -435,6 +435,16 @@ services: volumes: - ./zbx_env/var/lib/postgresql/data:/var/lib/postgresql/data:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_centos_mysql_latest.yaml b/docker-compose_v3_centos_mysql_latest.yaml index 4ef10de1f..525fb6cf9 100644 --- a/docker-compose_v3_centos_mysql_latest.yaml +++ b/docker-compose_v3_centos_mysql_latest.yaml @@ -382,6 +382,16 @@ services: volumes: - ./zbx_env/var/lib/mysql:/var/lib/mysql:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_centos_mysql_local.yaml b/docker-compose_v3_centos_mysql_local.yaml index d61f46bad..285dc2b84 100644 --- a/docker-compose_v3_centos_mysql_local.yaml +++ b/docker-compose_v3_centos_mysql_local.yaml @@ -414,6 +414,16 @@ services: volumes: - ./zbx_env/var/lib/mysql:/var/lib/mysql:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_centos_pgsql_latest.yaml b/docker-compose_v3_centos_pgsql_latest.yaml index 7ff9fd51c..db16c56d7 100644 --- a/docker-compose_v3_centos_pgsql_latest.yaml +++ b/docker-compose_v3_centos_pgsql_latest.yaml @@ -402,6 +402,16 @@ services: volumes: - ./zbx_env/var/lib/postgresql/data:/var/lib/postgresql/data:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_centos_pgsql_local.yaml b/docker-compose_v3_centos_pgsql_local.yaml index 57f004a01..6c8b50841 100644 --- a/docker-compose_v3_centos_pgsql_local.yaml +++ b/docker-compose_v3_centos_pgsql_local.yaml @@ -414,6 +414,16 @@ services: volumes: - ./zbx_env/var/lib/postgresql/data:/var/lib/postgresql/data:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_ubuntu_mysql_latest.yaml b/docker-compose_v3_ubuntu_mysql_latest.yaml index 4d30173a7..a739552b5 100644 --- a/docker-compose_v3_ubuntu_mysql_latest.yaml +++ b/docker-compose_v3_ubuntu_mysql_latest.yaml @@ -382,6 +382,16 @@ services: volumes: - ./zbx_env/var/lib/mysql:/var/lib/mysql:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_ubuntu_mysql_local.yaml b/docker-compose_v3_ubuntu_mysql_local.yaml index dedb8bbb3..2d338ef03 100644 --- a/docker-compose_v3_ubuntu_mysql_local.yaml +++ b/docker-compose_v3_ubuntu_mysql_local.yaml @@ -414,6 +414,16 @@ services: volumes: - ./zbx_env/var/lib/mysql:/var/lib/mysql:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_ubuntu_pgsql_latest.yaml b/docker-compose_v3_ubuntu_pgsql_latest.yaml index 0a0df2b5b..0b1b463c6 100644 --- a/docker-compose_v3_ubuntu_pgsql_latest.yaml +++ b/docker-compose_v3_ubuntu_pgsql_latest.yaml @@ -402,6 +402,16 @@ services: volumes: - ./zbx_env/var/lib/postgresql/data:/var/lib/postgresql/data:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/docker-compose_v3_ubuntu_pgsql_local.yaml b/docker-compose_v3_ubuntu_pgsql_local.yaml index e37181d60..f8807e13c 100644 --- a/docker-compose_v3_ubuntu_pgsql_local.yaml +++ b/docker-compose_v3_ubuntu_pgsql_local.yaml @@ -411,6 +411,16 @@ services: volumes: - ./zbx_env/var/lib/postgresql/data:/var/lib/postgresql/data:rw +# elasticsearch: +# image: elasticsearch +# environment: +# - transport.host=0.0.0.0 +# - discovery.zen.minimum_master_nodes=1 +# networks: +# zbx_net_backend: +# aliases: +# - elasticsearch + networks: zbx_net_frontend: driver: bridge diff --git a/java-gateway/alpine/docker-entrypoint.sh b/java-gateway/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/java-gateway/alpine/docker-entrypoint.sh +++ b/java-gateway/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/java-gateway/centos/docker-entrypoint.sh b/java-gateway/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/java-gateway/centos/docker-entrypoint.sh +++ b/java-gateway/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/java-gateway/ubuntu/docker-entrypoint.sh b/java-gateway/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/java-gateway/ubuntu/docker-entrypoint.sh +++ b/java-gateway/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/proxy-mysql/alpine/docker-entrypoint.sh b/proxy-mysql/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/proxy-mysql/alpine/docker-entrypoint.sh +++ b/proxy-mysql/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/proxy-mysql/centos/docker-entrypoint.sh b/proxy-mysql/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/proxy-mysql/centos/docker-entrypoint.sh +++ b/proxy-mysql/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/proxy-mysql/ubuntu/docker-entrypoint.sh b/proxy-mysql/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/proxy-mysql/ubuntu/docker-entrypoint.sh +++ b/proxy-mysql/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/proxy-sqlite3/alpine/docker-entrypoint.sh b/proxy-sqlite3/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/proxy-sqlite3/alpine/docker-entrypoint.sh +++ b/proxy-sqlite3/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/proxy-sqlite3/centos/docker-entrypoint.sh b/proxy-sqlite3/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/proxy-sqlite3/centos/docker-entrypoint.sh +++ b/proxy-sqlite3/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/proxy-sqlite3/ubuntu/docker-entrypoint.sh b/proxy-sqlite3/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/proxy-sqlite3/ubuntu/docker-entrypoint.sh +++ b/proxy-sqlite3/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/server-mysql/alpine/docker-entrypoint.sh b/server-mysql/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/server-mysql/alpine/docker-entrypoint.sh +++ b/server-mysql/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/server-mysql/centos/docker-entrypoint.sh b/server-mysql/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/server-mysql/centos/docker-entrypoint.sh +++ b/server-mysql/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/server-mysql/ubuntu/docker-entrypoint.sh b/server-mysql/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/server-mysql/ubuntu/docker-entrypoint.sh +++ b/server-mysql/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/server-pgsql/alpine/docker-entrypoint.sh b/server-pgsql/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/server-pgsql/alpine/docker-entrypoint.sh +++ b/server-pgsql/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/server-pgsql/centos/docker-entrypoint.sh b/server-pgsql/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/server-pgsql/centos/docker-entrypoint.sh +++ b/server-pgsql/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/server-pgsql/ubuntu/docker-entrypoint.sh b/server-pgsql/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/server-pgsql/ubuntu/docker-entrypoint.sh +++ b/server-pgsql/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-apache-mysql/alpine/conf/etc/zabbix/web/zabbix.conf.php b/web-apache-mysql/alpine/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-apache-mysql/alpine/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-apache-mysql/alpine/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-apache-mysql/alpine/docker-entrypoint.sh b/web-apache-mysql/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-apache-mysql/alpine/docker-entrypoint.sh +++ b/web-apache-mysql/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-apache-mysql/centos/conf/etc/zabbix/web/zabbix.conf.php b/web-apache-mysql/centos/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-apache-mysql/centos/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-apache-mysql/centos/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-apache-mysql/centos/docker-entrypoint.sh b/web-apache-mysql/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-apache-mysql/centos/docker-entrypoint.sh +++ b/web-apache-mysql/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-apache-mysql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php b/web-apache-mysql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-apache-mysql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-apache-mysql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-apache-mysql/ubuntu/docker-entrypoint.sh b/web-apache-mysql/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-apache-mysql/ubuntu/docker-entrypoint.sh +++ b/web-apache-mysql/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-apache-pgsql/alpine/conf/etc/zabbix/web/zabbix.conf.php b/web-apache-pgsql/alpine/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-apache-pgsql/alpine/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-apache-pgsql/alpine/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-apache-pgsql/alpine/docker-entrypoint.sh b/web-apache-pgsql/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-apache-pgsql/alpine/docker-entrypoint.sh +++ b/web-apache-pgsql/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-apache-pgsql/centos/conf/etc/zabbix/web/zabbix.conf.php b/web-apache-pgsql/centos/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-apache-pgsql/centos/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-apache-pgsql/centos/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-apache-pgsql/centos/docker-entrypoint.sh b/web-apache-pgsql/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-apache-pgsql/centos/docker-entrypoint.sh +++ b/web-apache-pgsql/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-apache-pgsql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php b/web-apache-pgsql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-apache-pgsql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-apache-pgsql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-apache-pgsql/ubuntu/docker-entrypoint.sh b/web-apache-pgsql/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-apache-pgsql/ubuntu/docker-entrypoint.sh +++ b/web-apache-pgsql/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-nginx-mysql/alpine/conf/etc/zabbix/web/zabbix.conf.php b/web-nginx-mysql/alpine/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-nginx-mysql/alpine/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-nginx-mysql/alpine/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-nginx-mysql/alpine/docker-entrypoint.sh b/web-nginx-mysql/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-nginx-mysql/alpine/docker-entrypoint.sh +++ b/web-nginx-mysql/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-nginx-mysql/centos/conf/etc/zabbix/web/zabbix.conf.php b/web-nginx-mysql/centos/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-nginx-mysql/centos/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-nginx-mysql/centos/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-nginx-mysql/centos/docker-entrypoint.sh b/web-nginx-mysql/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-nginx-mysql/centos/docker-entrypoint.sh +++ b/web-nginx-mysql/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-nginx-mysql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php b/web-nginx-mysql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-nginx-mysql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-nginx-mysql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-nginx-mysql/ubuntu/docker-entrypoint.sh b/web-nginx-mysql/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-nginx-mysql/ubuntu/docker-entrypoint.sh +++ b/web-nginx-mysql/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-nginx-pgsql/alpine/conf/etc/zabbix/web/zabbix.conf.php b/web-nginx-pgsql/alpine/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-nginx-pgsql/alpine/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-nginx-pgsql/alpine/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-nginx-pgsql/alpine/docker-entrypoint.sh b/web-nginx-pgsql/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-nginx-pgsql/alpine/docker-entrypoint.sh +++ b/web-nginx-pgsql/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-nginx-pgsql/centos/conf/etc/zabbix/web/zabbix.conf.php b/web-nginx-pgsql/centos/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-nginx-pgsql/centos/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-nginx-pgsql/centos/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-nginx-pgsql/centos/docker-entrypoint.sh b/web-nginx-pgsql/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-nginx-pgsql/centos/docker-entrypoint.sh +++ b/web-nginx-pgsql/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/web-nginx-pgsql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php b/web-nginx-pgsql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/web-nginx-pgsql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php +++ b/web-nginx-pgsql/ubuntu/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/web-nginx-pgsql/ubuntu/docker-entrypoint.sh b/web-nginx-pgsql/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/web-nginx-pgsql/ubuntu/docker-entrypoint.sh +++ b/web-nginx-pgsql/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/zabbix-appliance/alpine/conf/etc/zabbix/web/zabbix.conf.php b/zabbix-appliance/alpine/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/zabbix-appliance/alpine/conf/etc/zabbix/web/zabbix.conf.php +++ b/zabbix-appliance/alpine/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/zabbix-appliance/alpine/docker-entrypoint.sh b/zabbix-appliance/alpine/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/zabbix-appliance/alpine/docker-entrypoint.sh +++ b/zabbix-appliance/alpine/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/zabbix-appliance/centos/conf/etc/zabbix/web/zabbix.conf.php b/zabbix-appliance/centos/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/zabbix-appliance/centos/conf/etc/zabbix/web/zabbix.conf.php +++ b/zabbix-appliance/centos/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/zabbix-appliance/centos/docker-entrypoint.sh b/zabbix-appliance/centos/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/zabbix-appliance/centos/docker-entrypoint.sh +++ b/zabbix-appliance/centos/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/zabbix-appliance/rhel/conf/etc/zabbix/web/zabbix.conf.php b/zabbix-appliance/rhel/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/zabbix-appliance/rhel/conf/etc/zabbix/web/zabbix.conf.php +++ b/zabbix-appliance/rhel/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/zabbix-appliance/rhel/docker-entrypoint.sh b/zabbix-appliance/rhel/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/zabbix-appliance/rhel/docker-entrypoint.sh +++ b/zabbix-appliance/rhel/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG" diff --git a/zabbix-appliance/ubuntu/conf/etc/zabbix/web/zabbix.conf.php b/zabbix-appliance/ubuntu/conf/etc/zabbix/web/zabbix.conf.php index 4e6eb414e..a4c9fadab 100644 --- a/zabbix-appliance/ubuntu/conf/etc/zabbix/web/zabbix.conf.php +++ b/zabbix-appliance/ubuntu/conf/etc/zabbix/web/zabbix.conf.php @@ -1,6 +1,6 @@ +$IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG; + +// Elasticsearch url (can be string if same url is used for all types). +$HISTORY['url'] = '{ZBX_HISTORYSTORAGEURL}'; +// Value types stored in Elasticsearch. +$HISTORY['types'] = {ZBX_HISTORYSTORAGETYPES}; diff --git a/zabbix-appliance/ubuntu/docker-entrypoint.sh b/zabbix-appliance/ubuntu/docker-entrypoint.sh index 173ccd8bf..ea85f37db 100755 --- a/zabbix-appliance/ubuntu/docker-entrypoint.sh +++ b/zabbix-appliance/ubuntu/docker-entrypoint.sh @@ -842,6 +842,8 @@ prepare_zbx_web_config() { server_name=$(escape_spec_char "${ZBX_SERVER_NAME}") server_user=$(escape_spec_char "${DB_SERVER_ZBX_USER}") server_pass=$(escape_spec_char "${DB_SERVER_ZBX_PASS}") + history_storage_url=$(escape_spec_char "${ZBX_HISTORYSTORAGEURL}") + history_storage_types=$(escape_spec_char "${ZBX_HISTORYSTORAGETYPES}") sed -i \ -e "s/{DB_SERVER_HOST}/${DB_SERVER_HOST}/g" \ @@ -852,6 +854,8 @@ prepare_zbx_web_config() { -e "s/{ZBX_SERVER_HOST}/${ZBX_SERVER_HOST}/g" \ -e "s/{ZBX_SERVER_PORT}/${ZBX_SERVER_PORT}/g" \ -e "s/{ZBX_SERVER_NAME}/$server_name/g" \ + -e "s/{ZBX_HISTORYSTORAGEURL}/$history_storage_url/g" \ + -e "s/{ZBX_HISTORYSTORAGETYPES}/$history_storage_types/g" \ "$ZBX_WEB_CONFIG" [ "$db_type" = "postgresql" ] && sed -i "s/MYSQL/POSTGRESQL/g" "$ZBX_WEB_CONFIG"