Use of environment variables at dynamic configuration

My providers.yaml file contains

...
http:
   routers:
      rstudio_service:
          rule: Host(`rstudio.cn.lan`)
          service: rstudio_service
   services:
      rstudio_service:
         loadBalancer:
            servers:
            - url: http://nuc0c.cn.lan:8787

The question I have is:

at

rule: Host(`rstudio.cn.lan`)

how can I use an environment variable instead of rstudio.cn.lan ? Also, how to replace http://nuc0c.cn.lan:8787 with another environment variable at:

url: http://nuc0c.cn.lan:8787

Maybe check this post, they try to use Host(`prox.{{ env "DNS_ZONE" }}`).