如何防止DDEV覆盖.env变量或其他设置?

huangapple go评论43阅读模式
英文:

How can I prevent DDEV from overrwriting .env vars or other settings?

问题

每次ddev启动时,它都会覆盖我Laravel项目中的某些.env文件,比如DB_CONNECTION。团队中有些开发人员不使用ddev提供的mysql docker服务器,而是在本地机器上安装了一个考虑性能的mysql服务器。他们需要不同于ddev认为的.env变量。

我们能否阻止ddev修改.env文件?我认为这只发生在ddev的较新版本中,之前并不存在。

启动并保留环境变量,就好像(通过config.yaml中的标志)

英文:

Every time ddev starts up, it overwrites certain .env files in my Laravel project, like DB_CONNECTION.
Some dev's in the team don't use the mysql docker server that ddev providers, but have one installed on their local machine for performance considerations. They need different .env vars than ddev thinks.

Can we prevent ddev from modding the .env file? I believe it's only been the case for more recent versions of ddev, and wasn't there before.

Startup and leave the environment variables as if (perhaps via a flag in config.yaml)

答案1

得分: 0

DDEV提供了许多关于设置管理的功能,详见文档。您可能想要禁用设置管理:

disable_settings_management: true
英文:

DDEV provides lots of features for settings management, see docs. You probably want to disable settings management:

disable_settings_management: true

huangapple
  • 本文由 发表于 2023年2月23日 20:19:39
  • 转载请务必保留本文链接:https://go.coder-hub.com/75544748.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定