# Using global variables as map() parameter

**URL:** <https://discourse.haproxy.org/t/using-global-variables-as-map-parameter/8093>\
**Category:** Help!\
**Created:** [November 9, 2022, 9:08pm UTC](https://discourse.haproxy.org/t/using-global-variables-as-map-parameter/8093 "2022-11-09T21:08:56Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![shadyabhi](https://avatars.discourse-cdn.com/v4/letter/s/edb3f5/32.png) [@shadyabhi](https://discourse.haproxy.org/u/shadyabhi)\
**Post date:** [November 9, 2022, 9:08pm UTC](https://discourse.haproxy.org/t/using-global-variables-as-map-parameter/8093/1 "2022-11-09T21:08:56Z")

</div>

I was reading this section of HAproxy configuration, and it seems that we can access variables by this syntax:-

```auto
monitor fail if { var(proc.stopping) -m int gt 0 }

```

I’m setting a variable in `global section` as:-

```auto
set-var proc.location_admin_healthcheck_map str("./admin.map")

```

But, I’m unable to access that in `frontend section` as:-

```auto
acl is_good str(status),map(var(proc.location_admin_healthcheck_map)) -i -m str GOOD

```

The error I get is:-

```auto
[ALERT] (10321) : config : parsing [haproxy.cfg:20] : error detected while parsing ACL 'is_good' : invalid args in converter 'map' : failed to open pattern file <var(proc.location_admin_healthcheck_map> in ACL expression 'str(status),map(var(proc.location_admin_healthcheck_map))'.

```

`failed to open pattern file <var(proc.location_admin_healthcheck_map>` means the variable expansion never worked. What am I missing?
