# How to override environment variables via Newman

**URL:** <https://community.postman.com/t/how-to-override-environment-variables-via-newman/39015>\
**Category:** Help Hub\
**Tags:** newman-project, variables\
**Created:** [September 10, 2022, 5:42pm UTC](https://community.postman.com/t/how-to-override-environment-variables-via-newman/39015 "2022-09-10T17:42:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![spartanhooah](https://avatars.discourse-cdn.com/v4/letter/s/ecccb3/32.png) [@spartanhooah](https://community.postman.com/u/spartanhooah)\
**Post date:** [September 10, 2022, 5:42pm UTC](https://community.postman.com/t/how-to-override-environment-variables-via-newman/39015/1 "2022-09-10T17:42:03Z")

</div>

I have a Postman collection + environment variables file that gets run via Newman 4.1.0. I have a variable in the environment variables files called `domain`. In our pipeline, this is executed like `newman run "Our Tests.postman_collection.json" "--environment="Our Environment.postman_environment.json" --global-var "domain=$DOMAIN" --global-var "glooEnv=$COOKIE" --global-var "apiKey=$API_KEY" --env-var "glooCookie=key=value" --env-var "domain=https://some-url.com"` (where `DOMAIN = https://some-url.com`). The requests in the collection have as their URL `{{domain}}/path/to/resource`. However, when Newman runs the tests, I see the URL as `http:///path/to/resource`. Why is `domain` getting set to `http://`? In the environment file, it’s `http://localhost:8080`, and the value passed in from the command line is `https://some-url.com`.
