DEV Community

portfield
portfield

Posted on

Aurora Serverless Secrets Manager user information management (using CloudFormation)

In CloudFormation, I want to manage Aurora Serverless user login information using Secrets Manager.

At the moment, it works with mysql engine.

  SecretAuroraServerlessRoot:
    Type: AWS::SecretsManager::Secret
    Properties:
      Description: "Aurora Serverless Root Secrets" 
      SecretString: !Sub 
        -
          '{
              "dbInstanceIdentifier": "${RDSIdentifier}",
              "engine": "${RDSEngine}",
              "host": "${RDSHost}",
              "port": "${RDSPort}",
              "username": "${MasterUsername}", 
              "password": "${MasterUserPassword}"
           }'
        - 
          RDSIdentifier: !Ref AuroraServerlessCluster
          RDSEngine: mysql
          RDSHost: !GetAtt AuroraServerlessCluster.Endpoint.Address
          RDSPort: !GetAtt AuroraServerlessCluster.Endpoint.Port
      Name: !Sub ${TagName}_${EnvTag}_serverless_root_user

Top comments (0)