firstly create parameter in parameter store of AWS system manager
Then get the key from this code.
code
import boto3
ssm = boto3.client('ssm')
parameter = ssm.get_parameter(Name='/project/key_endpoint', WithDecryption=True)
print(parameter['Parameter']['Value'])
.
No comments:
Post a Comment