Giter Site home page Giter Site logo

Add support for Openstack Heat about cfndsl HOT 2 CLOSED

cfndsl avatar cfndsl commented on July 19, 2024
Add support for Openstack Heat

from cfndsl.

Comments (2)

howech avatar howech commented on July 19, 2024

It turns out if you restrict yourself to the following resources, cloudformation templates are reasonably compatible with Open Stack:

CloudFormation Compatible Resource Types
AWS::AutoScaling::AutoScalingGroup
AWS::AutoScaling::LaunchConfiguration
AWS::AutoScaling::ScalingPolicy
AWS::CloudFormation::Stack
AWS::CloudFormation::WaitCondition
AWS::CloudFormation::WaitConditionHandle
AWS::EC2::EIP
AWS::EC2::EIPAssociation
AWS::EC2::Instance
AWS::EC2::InternetGateway
AWS::EC2::NetworkInterface
AWS::EC2::RouteTable
AWS::EC2::SecurityGroup
AWS::EC2::Subnet
AWS::EC2::SubnetRouteTableAssociation
AWS::EC2::VPC
AWS::EC2::VPCGatewayAttachment
AWS::EC2::Volume
AWS::EC2::VolumeAttachment
AWS::ElasticLoadBalancing::LoadBalancer
AWS::IAM::AccessKey
AWS::IAM::User
AWS::RDS::DBInstance
AWS::S3::Buckett

Adding full OS support looks like a combination of things:

  1. fix output to allow yaml instead of json. This is probably trickier than it seems, and may not be necessary. However, yaml with references can make for a much condensed template over just json, so I think it is worth pursuing

  2. add support for the extra FNs that openstack provides. Fn::Replace is kind of nice, for instance.

  3. add support for all of the extra OS:: resources.

  4. To ensure the best possible validation, it might be nice to be able to specify somewhere whether you want your template to work in OS or CFN (or both!) and have type checking rules adjust appropriately.

More details can be found here: http://docs.openstack.org/developer/heat/template_guide/index.html

from cfndsl.

howech avatar howech commented on July 19, 2024

A recent pull request added some support for Heat.

You can create a JSON heat template using the top level function Heat, in much the same way you would do so with the function CloudFormation to create a cloudformation template. The language accepted within the Heat function is generated by a yaml file based on the contents of http://docs.openstack.org/developer/heat/template_guide/openstack.html and http://docs.openstack.org/developer/heat/template_guide/cfn.html .

Note some features implemented outside of the .yaml system will still 'work' for openstack, although they will then incorrectly generate templates that are not valid Heat templates. Conditionals, for example. Also note the Heat's FnReplace function has not been implemented. FnFormat should satisfy the same kinds of needs, and I can only think of some strange corner cases where you would care which one you ended up with.

from cfndsl.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.