saltstack-formulas / zabbix-formula

http://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html
Other
50 stars 121 forks source link

feat(frontend): allow to set that db history tables were updated (zabbix 5.0+) #152

Open ghormoon opened 3 years ago

ghormoon commented 3 years ago

PR progress checklist (to be filled in by reviewers)


What type of PR is this?

Primary type

Secondary type

Does this PR introduce a BREAKING CHANGE?

No.

Related issues and/or pull requests

Describe the changes you're proposing

Zabbix 5.0 will complain in froentend with "Database history tables upgraded | No" unless a variable is set ij web connfig file. Unfortunately upgrading the tables is not enough, it needs to be told in config too. This should be done in pillar when upgrading.

Pillar / config required to test the proposed changes

zabbix:
  lookup:
    version_repo: 5.4
    frontend:
      historyupgraded: true

Debug log showing how the proposed changes work

          ID: /etc/zabbix/web/zabbix.conf.php
    Function: file.managed
      Result: True
     Comment: File /etc/zabbix/web/zabbix.conf.php updated
     Started: 14:52:25.967616
    Duration: 224.967 ms
     Changes:   
              ----------
              diff:
                  --- 
                  +++ 
                  @@ -16,4 +16,5 @@
                   $ZBX_SERVER_NAME             = 'Zabbix installed with SaltStack';

                   $IMAGE_FORMAT_DEFAULT        = IMAGE_FORMAT_PNG;
                  +$DB['DOUBLE_IEEE754'] = 'true';
                   ?>

Documentation checklist

Testing checklist

Additional context