Allow custom DB name for Proxy SQLite3 variant

This commit is contained in:
Alexey Pustovalov 2021-08-04 17:50:10 +02:00
parent 2fde266b3b
commit f7ee3f6e57
6 changed files with 13 additions and 3 deletions

View File

@ -34,6 +34,7 @@ RUN set -eux && \
zabbix && \
mkdir -p /etc/zabbix && \
mkdir -p /var/lib/zabbix && \
mkdir -p /var/lib/zabbix/db_data && \
mkdir -p /var/lib/zabbix/enc && \
mkdir -p /var/lib/zabbix/mibs && \
mkdir -p /var/lib/zabbix/modules && \

View File

@ -199,6 +199,10 @@ Please use official documentation for [``zabbix_proxy.conf``](https://www.zabbix
The volume is used by External checks (type of items). It is `ExternalScripts` parameter in ``zabbix_proxy.conf``.
### ``/var/lib/zabbix/db_data``
The volume stores SQLite3 database file and could be used for external database file storage.
### ``/var/lib/zabbix/modules``
The volume allows load additional modules and extend Zabbix proxy using ``LoadModule`` feature.

View File

@ -139,7 +139,7 @@ update_zbx_config() {
update_config_var $ZBX_CONFIG "LogRemoteCommands" "${ZBX_LOGREMOTECOMMANDS}"
update_config_var $ZBX_CONFIG "DBHost"
update_config_var $ZBX_CONFIG "DBName" "/var/lib/zabbix/zabbix_proxy_db"
update_config_var $ZBX_CONFIG "DBName" "/var/lib/zabbix/db_data/${ZBX_HOSTNAME:-"zabbix-proxy-sqlite3"}.sqlite"
update_config_var $ZBX_CONFIG "DBUser"
update_config_var $ZBX_CONFIG "DBPort"
update_config_var $ZBX_CONFIG "DBPassword"

View File

@ -69,6 +69,7 @@ RUN set -eux && INSTALL_PKGS="bash \
zabbix && \
mkdir -p /etc/zabbix && \
mkdir -p /var/lib/zabbix && \
mkdir -p /var/lib/zabbix/db_data && \
mkdir -p /var/lib/zabbix/enc && \
mkdir -p /usr/lib/zabbix/externalscripts && \
mkdir -p /var/lib/zabbix/mibs && \

View File

@ -199,6 +199,10 @@ Please use official documentation for [``zabbix_proxy.conf``](https://www.zabbix
The volume is used by External checks (type of items). It is `ExternalScripts` parameter in ``zabbix_proxy.conf``.
### ``/var/lib/zabbix/db_data``
The volume stores SQLite3 database file and could be used for external database file storage.
### ``/var/lib/zabbix/modules``
The volume allows load additional modules and extend Zabbix proxy using ``LoadModule`` feature.
@ -248,7 +252,7 @@ To minimize image size, it's uncommon for additional related tools (such as `git
This is the defacto image. If you are unsure about what your needs are, you probably want to use this one. It is designed to be used both as a throw away container (mount your source code and start the container to start your app), as well as the base to build other images off of.
## `zabbix-agent:ol-<version>`
## `zabbix-proxy-sqlite3:ol-<version>`
Oracle Linux is an open-source operating system available under the GNU General Public License (GPLv2). Suitable for general purpose or Oracle workloads, it benefits from rigorous testing of more than 128,000 hours per day with real-world workloads and includes unique innovations such as Ksplice for zero-downtime kernel patching, DTrace for real-time diagnostics, the powerful Btrfs file system, and more.

View File

@ -139,7 +139,7 @@ update_zbx_config() {
update_config_var $ZBX_CONFIG "LogRemoteCommands" "${ZBX_LOGREMOTECOMMANDS}"
update_config_var $ZBX_CONFIG "DBHost"
update_config_var $ZBX_CONFIG "DBName" "/var/lib/zabbix/zabbix_proxy_db"
update_config_var $ZBX_CONFIG "DBName" "/var/lib/zabbix/db_data/${ZBX_HOSTNAME:-"zabbix-proxy-sqlite3"}.sqlite"
update_config_var $ZBX_CONFIG "DBUser"
update_config_var $ZBX_CONFIG "DBPort"
update_config_var $ZBX_CONFIG "DBPassword"