What if I want to use files in gitignore

ε祈祈猫儿з 提交于 2021-02-08 05:45:43

问题


For sensitive data such as aws keys or password, I put them to files which is in .gitignore to make sure it is not committed to git. However, when keys are going to be used when scripts are running, what should I do? Manually add key content in a file before running? What if the program need to be triggered periodically by Jenkins?

Can anyone help me with this?


回答1:


Manually add key content in a file before running?

That is the general idea: sensitive information should not be in a Git repo, but in an external referential, like a Vault.

Once you have a script able to extract that information from a vault, you could call that script automatically on checkout through a git content filter driver.



来源:https://stackoverflow.com/questions/48727991/what-if-i-want-to-use-files-in-gitignore

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!