# Proxy entity with multiple proxy checks

**URL:** https://discourse.sensu.io/t/proxy-entity-with-multiple-proxy-checks/1892
**Category:** Sensu Go
**Created:** [June 16, 2020, 3:17pm UTC](https://discourse.sensu.io/t/proxy-entity-with-multiple-proxy-checks/1892 "2020-06-16T15:17:15Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![wedwards](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.sensu.io/wedwards/32/280_2.png) [@wedwards](https://discourse.sensu.io/u/wedwards)
#### Post date: [June 16, 2020, 3:17pm UTC](https://discourse.sensu.io/t/proxy-entity-with-multiple-proxy-checks/1892/1 "2020-06-16T15:17:15Z")

</div>

Hello,

Suppose this situation: I have one mail server which runs IMAP, SMTP and POP. I would like to execute proxy checks for IMAP, SMTP and POP. I would like those checks to be a part of one proxy entity, such as `mailserver.tld`

To do this, I should:

- Make my entity’s `proxy_type` entity attribute a list (e.g.: `imap`, `pop`, `smtp`)
- Change proxy check’s `entity.labels.proxy_type` to check if the value is _in_ `proxy_type` instead of if `proxy_type` matches its value (`"entity.labels.proxy_type == '{{ item.name }}'"`)

However, according to [https://docs.sensu.io/sensu-go/latest/reference/filters/#syntax-quick-reference](https://docs.sensu.io/sensu-go/latest/reference/filters/#syntax-quick-reference), I cannot check if the value is in the list, which would make it impossible to do this.

Is this correct?

---

<div class="post-metadata">

### Author: ![todd](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.sensu.io/todd/32/936_2.png) [@todd](https://discourse.sensu.io/u/todd)
#### Post date: [June 16, 2020, 4:11pm UTC](https://discourse.sensu.io/t/proxy-entity-with-multiple-proxy-checks/1892/2 "2020-06-16T16:11:39Z")

</div>

I believe you are correct in that lists are not supported for these attributes.

I think the following might work better:

- Make the entity’s `proxy_type` attribute `mailserver`
- Create 3 checks, one each for IMAP, SMTP, and POP and set the `entity.labels.proxy_type == 'mailserver'`

---

<div class="post-metadata">

### Author: ![wedwards](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.sensu.io/wedwards/32/280_2.png) [@wedwards](https://discourse.sensu.io/u/wedwards)
#### Post date: [June 16, 2020, 6:09pm UTC](https://discourse.sensu.io/t/proxy-entity-with-multiple-proxy-checks/1892/3 "2020-06-16T18:09:09Z")

</div>

That seems to work, kind of. I have that working with an `or` conditional so I can reuse checks, but no events seem to be generated when there’s a lot of `entity.labels.proxy_type` values. Will debug further…
