13.5.12. Custom Environment Variables


Custom environment variables are user defined to use with applications.
Setting Custom Environment Variables

Set one of more environment variables for an application with the following command:

$ rhc env set Variable=Value Variable2=Value2 -a App_Namerhc env set Variable=Value Variable2=Value2 -a App_Namerhc env set Variable=Value Variable2=Value2 -a App_Namerhc env set Variable=Value Variable2=Value2 -a App_Namerhc env set Variable=Value Variable2=Value2 -a App_Namerhc env set Variable=Value Variable2=Value2 -a App_Name
Copy to Clipboard Toggle word wrap
Add additional Variable=Value arguments separated by spaces to set multiple variables.

Viewing Custom Environment Variables

View the custom environment variables set for an application with the following command:

$ rhc env list -a App_Namerhc env list -a App_Name
Copy to Clipboard Toggle word wrap

Viewing the Value of a Custom Environment Variable

Display the value of one or more custom environment variables with the following command:

$ rhc env show Variable Variable2 -a App_Namerhc env show Variable Variable2 -a App_Namerhc env show Variable Variable2 -a App_Namerhc env show Variable Variable2 -a App_Name
Copy to Clipboard Toggle word wrap

Removing Custom Environment Variables

Remove a custom environment variable with the following command:

$ rhc env unset Variable -a App_Namerhc env unset Variable -a App_Namerhc env unset Variable -a App_Namerhc env unset Variable -a App_Name
Copy to Clipboard Toggle word wrap

Back to top
Red Hat logoGithubredditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust. Explore our recent updates.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

Theme

© 2025 Red Hat