How to use enable_key_rotation method in localstack

Best Python code snippet using localstack_python

key.py

Source:key.py Github

copy

Full Screen

...157 """158 return pulumi.get(self, "description")159 @property160 @pulumi.getter(name="enableKeyRotation")161 def enable_key_rotation(self) -> pulumi.Output[Optional[bool]]:162 """163 Specifies whether [key rotation](http://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html) is enabled. Defaults to false.164 """165 return pulumi.get(self, "enable_key_rotation")166 @property167 @pulumi.getter(name="isEnabled")168 def is_enabled(self) -> pulumi.Output[Optional[bool]]:169 """170 Specifies whether the key is enabled. Defaults to true.171 """172 return pulumi.get(self, "is_enabled")173 @property174 @pulumi.getter(name="keyId")175 def key_id(self) -> pulumi.Output[str]:...

Full Screen

Full Screen

kms_stack.py

Source:kms_stack.py Github

copy

Full Screen

1from aws_cdk import (2 aws_kms as kms,3 core4) 5class KMSStack(core.Stack):6 def __init__(self, scope: core.Construct, id: str, **kwargs) -> None:7 super().__init__(scope, id, **kwargs)8 prj_name = self.node.try_get_context("project_name")9 env_name = self.node.try_get_context("env")10 self.kms_rds = kms.Key(self,"dbkey",11 enable_key_rotation=True,12 description="{}-{}-key-rds".format(prj_name,env_name)13 )14 self.kms_rds.add_alias(15 alias_name="alias/{}-{}-key-rds".format(prj_name,env_name)16 )17 kms_redis = kms.Key(self,"rediskey",18 enable_key_rotation=True,19 description="{}-{}-key-redis".format(prj_name,env_name)20 )21 kms_redis.add_alias(22 alias_name="alias/{}-{}-key-redis".format(prj_name,env_name)23 )24 kms_lambda = kms.Key(self,"lambdakey",25 enable_key_rotation=True,26 description="{}-{}-key-lambda".format(prj_name,env_name)27 )28 kms_lambda.add_alias(29 alias_name="alias/{}-{}-key-lambda".format(prj_name,env_name)30 )31 32 core.CfnOutput(self,"rdskeyexport",33 value=self.kms_rds.key_arn34 )35 core.CfnOutput(self,"lambdakeyexport",36 value=kms_lambda.key_arn,37 export_name="lambda-kms-key"38 )39 core.CfnOutput(self,"rediskeyexport",40 value=kms_redis.key_arn,41 export_name="redis-kms-key"42 )43 44 45 46 47 ...

Full Screen

Full Screen

Automation Testing Tutorials

Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.

LambdaTest Learning Hubs:

YouTube

You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.

Run localstack automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful