# How to pass parameters in deploy mode

**URL:** <https://drone.discourse.group/t/how-to-pass-parameters-in-deploy-mode/10575>\
**Category:** Drone Support\
**Created:** [November 12, 2020, 2:05am UTC](https://drone.discourse.group/t/how-to-pass-parameters-in-deploy-mode/10575 "2020-11-12T02:05:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![niaiwomattt](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/niaiwomattt/32/3474_2.png) [@niaiwomattt](https://drone.discourse.group/u/niaiwomattt)\
**Post date:** [November 12, 2020, 2:05am UTC](https://drone.discourse.group/t/how-to-pass-parameters-in-deploy-mode/10575/1 "2020-11-12T02:05:54Z")

</div>

How to pass parameters in deploy mode. After I pass them, they cannot be seen in the environment variables. How do I receive them?

---

<div class="post-metadata">

**Author:** ![niaiwomattt](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/niaiwomattt/32/3474_2.png) [@niaiwomattt](https://drone.discourse.group/u/niaiwomattt)\
**Post date:** [November 12, 2020, 2:07am UTC](https://drone.discourse.group/t/how-to-pass-parameters-in-deploy-mode/10575/2 "2020-11-12T02:07:33Z")

</div>

```bash
---
kind: pipeline
type: docker
name: default

steps:
- name: tpl-reaplace
 image: repository.241210.com/repository/gyys/tpl:2
 commands:
   - TPL_PATH="./yaml/*.yaml" TPL_VALUESPATH="./yamlvalues/*.toml" TPL_OUTPATH="./yamlout/" TPL_COMMONPATH="./yamlvalues/common/" TPL_TAG="develop" tpl
   - ls ./yamlout/
   - env

- name: develop
 image: repository.241210.com/repository/gyys/tpl:2
 commands:
   - env
   - TPL_PATH="./yaml/*.yaml" TPL_VALUESPATH="./yamlvalues/*.toml" TPL_OUTPATH="./yamlout/" TPL_COMMONPATH="./yamlvalues/common/" TPL_TAG="${deploy}" tpl
   - ls ./yamlout/
 when:
   target:
     - develop
     - test
     - prod
   environment:
     - deploy

```

---

<div class="post-metadata">

**Author:** ![csgitharness](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/csgitharness/32/904_2.png) [@csgitharness](https://drone.discourse.group/u/csgitharness)\
**Post date:** [November 12, 2020, 12:00pm UTC](https://drone.discourse.group/t/how-to-pass-parameters-in-deploy-mode/10575/3 "2020-11-12T12:00:45Z")

</div>

Hi,

If you need to customize Drone in order to pass additional environment variables to your pipeline, the recommended approach is to create an environment extension. See [https://docs.drone.io/extensions/environment/](https://docs.drone.io/extensions/environment/)

It sounds like an environment extension (described above) is the best approach if you need something more dynamic and custom, but you can also load global environment variable from a file by providing the runner with an environment file:  
[https://docs.drone.io/runner/docker/configuration/reference/drone-runner-env-file/](https://docs.drone.io/runner/docker/configuration/reference/drone-runner-env-file/)
