|
|
@@ -23,8 +23,10 @@ class EC2Instance(Instance):
|
|
|
def name(self):
|
|
|
"""
|
|
|
Get the instance name.
|
|
|
+
|
|
|
+ .. note:: an instance must have a (case sensitive) tag ``Name``
|
|
|
"""
|
|
|
- return self._ec2_instance.tags['Name']
|
|
|
+ return self._ec2_instance.tags.get('Name')
|
|
|
|
|
|
@name.setter
|
|
|
def name(self, value):
|
|
|
@@ -92,4 +94,4 @@ class EC2Instance(Instance):
|
|
|
"""
|
|
|
Get the name of the key pair associated with this instance.
|
|
|
"""
|
|
|
- return BaseKeyPair(self._ec2_instance.key_name)
|
|
|
+ return BaseKeyPair(self._ec2_instance.key_name)
|