AWS ECS - 一种免费的秘密传递方式

AWS ECS - a free way for passing secrets

我有一个简单的应用程序作为 AWS ECS。 现在我想将它与数据库 (AWS RDS) 集成。

问题是 - 我需要将 RDS 凭据传递到我的 docker 图像,例如。以安全的方式作为环境变量。

经过一番研究,我找到了两种方法:
- AWS 秘密管理器
- AWS 系统管理器参数存储

但是...他们都得到了报酬。

  1. Secrets Manager 每月 1 个机密的费用为 0.40 美元。
  2. System Manager Parameter Store 需要 'Customer Managed Key',这也需要 1 美元/月。

作为免费层用户,对于我的简单应用程序,我宁愿不为仅 'storing secrets' 付费。那么...是否有任何其他安全和推荐的方法将敏感数据传递到托管在 ECS 上的 docker 应用程序?

System Manager Parameter Store requires 'Customer Managed Key' which also costs 1$/month.

事实并非如此。仅当您想使用自己的 CMK 时才需要这样做。如果没有,那么您可以使用 AWS 的 default CMK provided free:

SecureString data is encrypted and decrypted using a AWS Key Management Service (KMS) key. You can use either a default KMS key provided by AWS or create and use your own customer master key (CMK).

同样在免费套餐中,每个请求有 20,000 个 api month:

AWS Free Tier includes 20,000 free AWS Key Management Service requests each month.