J
J
Jekson2020-08-13 09:42:07
Python
Jekson, 2020-08-13 09:42:07

How to add a variable to os.environ?

Django project, OS-Ubuntu
there is a line if os.environ.get('EVEL')
I thought to add a variable EVELto the file .bashrc
###
export EVEL=1
###
but it didn't help.
When I execute print(os.environ)that output content, there is no .bashrc
where at all and how to add environment variables?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
J
Jekson, 2020-08-13
@Lepilov

Rebooted the car and went. I wonder if there is a way without rebooting?

Z
zexer, 2020-08-13
@zexer

https://stackoverflow.com/questions/5971312/how-to...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question