jhipster application-prod.yml将敏感信息存储在github上 [英] jhipster application-prod.yml stores sensitive info on github
本文介绍了jhipster application-prod.yml将敏感信息存储在github上的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想让我的smtp登录信息保密。每次我必须部署到生产环境时,编辑application-prod.yml是个麻烦。
I want to keep my smtp login information private. And its a hassle to edit application-prod.yml every time I have to deploy to production.
避免在application-prod中存储敏感细节的正确方法是什么? yml on github?
What is the correct method to avoid storing sensitive details in application-prod.yml on github ?
推荐答案
许多不同的方法取决于您在何处以及如何部署到:
Many different ways depending on where and how you deploy to:
- 不要将application-prod.yml存储在git中,也不要将其打包到您的jar中。
- 不要将秘密存储在application-prod.yml,使用环境变量或命令行选项。请参阅 Spring Boot doc a>。
- 使用 git-crypt 加密机密in application-prod.yml
- 在外部Spring Cloud Config Server中存储机密信息(例如 JHipster注册表)或 HashiCorp Vault
- Don't store application-prod.yml in git and don't package it in your jar
- Don't store secrets in application-prod.yml, use environment variables or command line options. See Spring Boot doc.
- Encrypt secrets using git-crypt in application-prod.yml
- Store secrets in external Spring Cloud Config Server (e.g. JHipster Registry) or HashiCorp Vault
以及其他许多方法...
and many other ways...
这篇关于jhipster application-prod.yml将敏感信息存储在github上的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文