<s> from troposphere import AWSObject , AWSProperty <EOL> from troposphere . validators import boolean , integer , network_port <EOL> class BlockDeviceMapping ( AWSProperty ) : <EOL> props = { <EOL> '<STR_LIT>' : ( boolean , False ) , <EOL> '<STR_LIT>' : ( basestring , True ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( integer , False ) , <EOL> } <EOL> class Network ( AWSProperty ) : <EOL> props = { <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT:port>' : ( network_port , False ) , <EOL> } <EOL> class FloatingIP ( AWSObject ) : <EOL> resource_type = "<STR_LIT>" <EOL> props = { <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> } <EOL> class FloatingIPAssociation ( AWSObject ) : <EOL> resource_type = "<STR_LIT>" <EOL> props = { <EOL> '<STR_LIT>' : ( basestring , True ) , <EOL> '<STR_LIT>' : ( basestring , True ) , <EOL> } <EOL> class KeyPair ( AWSObject ) : <EOL> resource_type = "<STR_LIT>" <EOL> props = { <EOL> '<STR_LIT:name>' : ( basestring , True ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( boolean , False ) , <EOL> } <EOL> class Server ( AWSObject ) : <EOL> resource_type = "<STR_LIT>" <EOL> props = { <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( list , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT:image>' : ( basestring , True ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( dict , False ) , <EOL> '<STR_LIT:name>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( dict , False ) , <EOL> '<STR_LIT>' : ( list , True ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( dict , False ) , <EOL> '<STR_LIT>' : ( list , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> '<STR_LIT>' : ( basestring , False ) , <EOL> } <EOL> def validate ( self ) : <EOL> if '<STR_LIT>' in self . resource : <EOL> diskConfig = self . resource [ '<STR_LIT>' ] <EOL> if diskConfig not in [ '<STR_LIT>' , '<STR_LIT>' ] : <EOL> raise ValueError ( <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" ) <EOL> if '<STR_LIT>' in self . resource : <EOL> flavor_update_policy = self . resource [ '<STR_LIT>' ] <EOL> if flavor_update_policy not in [ '<STR_LIT>' , '<STR_LIT>' ] : <EOL> raise ValueError ( <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" ) <EOL> if '<STR_LIT>' in self . resource : <EOL> image_update_policy = self . resource [ '<STR_LIT>' ] <EOL> if image_update_policy not in [ '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' ] : <EOL> raise ValueError ( <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" ) <EOL> if '<STR_LIT>' in self . resource : <EOL> sct = self . resource [ '<STR_LIT>' ] <EOL> if sct not in [ '<STR_LIT>' , '<STR_LIT>' ] : <EOL> raise ValueError ( <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" ) <EOL> if '<STR_LIT>' in self . resource : <EOL> user_data_format = self . resource [ '<STR_LIT>' ] <EOL> if user_data_format not in [ '<STR_LIT>' , '<STR_LIT>' ] : <EOL> raise ValueError ( <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" ) <EOL> return True </s>
