Skip to content

Conversation

weedge
Copy link

@weedge weedge commented Nov 23, 2024

No description provided.

@wangyoucao577
Copy link
Collaborator

What's the benefit of this change?

@weedge
Copy link
Author

weedge commented Nov 25, 2024

change .env file in project root dir in docker container ; if environment variables has defined in sys user mode, can't to load those in the .env file; just use environment variables which defined in .env file.

@wangyoucao577
Copy link
Collaborator

change .env file in project root dir in docker container ; if environment variables has defined in sys user mode, can't to load those in the .env file; just use environment variables which defined in .env file.

Does source .env work for you?

@weedge
Copy link
Author

weedge commented Nov 27, 2024

@wangyoucao577 yes, is work, need set vars in .env

AGORA_APP_ID=***
AGORA_APP_CERTIFICATE=***

if not set those env, use user mod defined vars $AGORA_APP_CERTIFICATE,
if vars both in .env and defined vars; so want use Overload use vars in .env; :)

@wangyoucao577
Copy link
Collaborator

@wangyoucao577 yes, is work, need set vars in .env

AGORA_APP_ID=***
AGORA_APP_CERTIFICATE=***

if not set those env, use user mod defined vars $AGORA_APP_CERTIFICATE, if vars both in .env and defined vars; so want use Overload use vars in .env; :)

OK. So use overload to force to use .env seems a little bit no sense here. export XXX should has higher priority than .env, which is more intuitive. On the other hand, the godotenv also warns that use the Overload if needed with caution. So use Overload instead of Load here may not a good choice.

@weedge
Copy link
Author

weedge commented Nov 29, 2024

..... but just change the Secrets(such as api key, app token) in .env file, don't to use in user mode defined vars. unsafe.

@halajohn halajohn self-requested a review as a code owner June 22, 2025 06:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants