Allow Description in properties schema

The resource document generation already expects
and uses any supplied Description text.

Change-Id: Ife31cd99f6ff88345c3c06e3efeb4b3393e6351b
Create a Schema from a parameter

Add a classmethod to create a property Schema object directly from a
parameter schema.

Change-Id: I335ec48086ea5aeb1fb2afd9af8e93529d9b6051
Wrap the resource registration in a global environment

Change-Id: I065dadc9fae19ab21d6d4aeae08334f20da161bb
Merge "Allow Description in properties schema"
Convert heat.common.template_format to use C yaml

Will fall back to pyyaml if CSafeLoader/CSafeDumper are not available.
This should increase template parsing performance by a factor of 9 and
reduce memory usage by an order of magnitude.

We also convert the one test that was directly calling yaml to use the
template_format.parse function, so that the same parsing is used
everywhere.

Change-Id: I0d14be2ef7fb2dccac43fc41b1d2d9e4395c6f77
Fixes bug #1214580
Introduce nova_utils.server_to_ipaddress

Create a utility function used for now by the instance and load balancer
resources to retrieve one IP of a nova server.

Change-Id: I87ace4c61b03a66f3b0c30f3bacd2fce79332ed0
Merge "Wrap the resource registration in a global environment"
Merge "Create a Schema from a parameter"
Use Template to instantiate TemplateResource

Use the Template class, rather than the raw template data, to obtain the
information required to create the schema of a TemplateResource facade.
This will allow this feature to work with multiple template formats (e.g.
HOT vs. CloudFormation).

Change-Id: Ifde739b081e95ed9f14567f35a0a1680c5e9b631
Generate property Schema objects directly from parameters

Use Schema.from_parameter() instead of Property.schema_from_param() to
generate a property schema from a parameter schema.

Change-Id: I1049822057d954ddbb47027aad136f7b45541943
Remove the Property.schema_from_param() method

This is now unused.

Change-Id: I5da20effe72a791d6dd8e9cc99ec9e43dea2da07
Add new attributes to EIPAssociation resource

AllocationId
NetworkInterfaceId

The EIP resource also now supports the Domain property, which when set
creates the resource using neutron networking. (Neutron networking is
required for all VPC operations.)

The EIP test covers the new functionality as well as some of the old
using both nova and neutron.

Fixes bug #1164865
Fixes bug #1164866

Change-Id: I7ad7fba8ed6f8a584fc2ca00aaf80144c5274134
Add an environment_format.py like the template one

This to make the section checking mechanism less spread out
and more consistent. This can also be used by the global
environment loader.

Change-Id: I7ca7ad754fb702877dedc416a30f573d239933ad
Load deployer/global environment files at startup

This allows for a global environment that the deployer can use to set
their own defaults.
An example /etc/heat/environment.d/x.yaml

resource_registry:
  "OS::Quantum*": "OS::Neutron*"
  "AWS::RDS::DBInstance": "file:///etc/heat/templates/AWS_RDS_DBInstance.template"

Change-Id: Iee647a109e5a41d41cd4a79909c6edaca0d17b87
Use the global environment to define AWS::CloudWatch::Alarm

This will make it easier for the deployer to define the default
implementation.

Change-Id: If1a8dceb4ad2cade90a56f16dd450e571425c4a6
Add UpdatePolicy attribute to Instance/AutoScalingGroup

This is the second part of a series to implement support
for AutoScaling UpdatePolicy.

Defined new update_policy attribute for InstanceGroup
and AutoScalingGroup, and modified init of InstanceGroup and
AutoScalingGroup to parse UpdatePolicy from the template.
Currently, only InstanceGroup and AutoScalingGroup manages
update using UpdatePolicy and so this is not implemented in the
Resource class. This can be revisited when UpdatePolicy is
applicable to other resource types. The resource validation
method is also overridden here to validate the UpdatePolicy.
Included tests to validate various uses cases of templates
with, with bad, without, and removal of UpdatePolicy. This
patch does not address handling of instances update with
UpdatePolicy yet. The next patch will address that.

Change-Id: I1faf1a8a3ba1faf063b6687b34b57b2a96c6bfa8
blueprint: as-update-policy
Always validate auth_uri with allowed_auth_uris

The original intention was to allow heat to orchestrate
on any requested cloud when allowed_auth_uris is configured
with an empty list.

This change makes all requests be validated against
allowed_auth_uris for the following reasons:
- there is a potential security issue with requests
  being authorised by a fake keystone, allowing an exploit in
  heat to be executed without any valid authentication factors
  first being presented.
- ec2token middleware will also need to be made multi-cloud aware
  however as a compatible API it is not possible to specify the desired
  auth_uri with each request. Instead ec2token will need a list of
  configured endpoints so that it can try each one until a request
  is authenticated.

Change-Id: I3d6b7edf381a66b87b6e1fae07bc5dbe9db024bc
Replace httplib with requests for ec2tokens auth

This vastly simplifies the implementation and test mocking.

ec2token middleware is the last piece of code in the heat
repository to be making direct httplib calls.

Change-Id: I3807b27a7699ff19eb46e2721aaa5afd9d6c8ff9
Fix crash in "make html" introduced by the global env

Change-Id: Iece0e122841829d3561b71575065ffa7b656b504
Fix some flake8 warnings in doc/resources.py

remove doc from the ignore and just fix the issues in conf.py

Change-Id: I30833dd24409087c3482d2034a797fea3f90aa85