Fixed VAULT_CERT_FILE detection

This commit is contained in:
Alexey Pustovalov 2024-04-26 15:43:18 +09:00
parent 25d7215712
commit cd52a48021
18 changed files with 18 additions and 18 deletions

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');

View File

@ -33,7 +33,7 @@ $DB['VAULT_DB_PATH'] = getenv('ZBX_VAULTDBPATH');
$DB['VAULT_TOKEN'] = getenv('VAULT_TOKEN');
if (file_exists('/etc/zabbix/web/certs/vault.crt')) {
$DB['VAULT_CERT_FILE'] = file_exists('/etc/zabbix/web/certs/vault.crt');
$DB['VAULT_CERT_FILE'] = '/etc/zabbix/web/certs/vault.crt';
}
elseif (file_exists(getenv('ZBX_VAULTCERTFILE'))) {
$DB['VAULT_CERT_FILE'] = getenv('ZBX_VAULTCERTFILE');