[BUG] zabbix salt state not creating a user media
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 15.7k
- Forks
- 5.6k
- Avg merge
- 2d 44m
- Merged PRs (30d)
- 80
Description
Description
zabbix user present state is creating the user in zabbix but didn't create a user media.
Setup
saltstack is running with version 3004.2 and have two zabbix servers which are running in version 5.4.2 and 6.2.2
***Salt_State_and_Results ***
create_john:
zabbix_user.present:
- alias: johnd
- passwd: xxxxxxxxxxxxx
- firstname: John
- surname: doe
- roleid: 2
- usrgrps:
- 7
- medias:
- johnd@example.com:
- mediatype: mail
- period: '1-7,00:00-24:00'
- severity: AHD
- active: true
Initial execution of above state and when I check it doesn't create user media.
ID: create_john
Function: zabbix_user.present
Result: True
Comment: User john created.
Started: 10:04:32.486646
Duration: 1897.273 ms
Changes:
----------
john:
----------
new:
User john created.
old:
User john does not exist.
Summary for ip-10-246-106-187.ec2.internal
Succeeded: 1 (changed=1)
Failed: 0
Second time execution and thereafter, still it doesn't create / attach media to the user
ID: create_john
Function: zabbix_user.present
Result: True
Comment: User john updated.
Started: 10:42:21.519417
Duration: 4395.031 ms
Changes:
----------
medias:
[{'active': '1', 'mediatypeid': '1', 'period': '1-7,00:00-24:00', 'sendto': 'johnd@example.com', 'severity': '32'}]
Summary for ip-10-246-106-187.ec2.internal
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the zabbix_user.present state and reproduce the supplied Salt state against the reported Zabbix 5.4.2 and 6.2.2 versions. Trace why the media is absent after the initial run; the issue is done when the user media is created or attached on the first run and subsequent runs remain correct.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- devops, infrastructure
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100