fuel-ccp-heat/service/heat-api-cfn.yaml

76 lines
2.3 KiB
YAML

dsl_version: 0.1.0
service:
name: heat-api-cfn
ports:
- {{ heat.api_cfn_port }}
containers:
- name: heat-api-cfn
image: heat-api-cfn
pre:
- name: heat-cfn-service-create
dependencies:
- keystone-create-project
type: single
command:
openstack service create --name heat-cfn --description "Heat CloudFormation Service" cloudformation
- name: heat-cfn-public-endpoint-create
dependencies:
- heat-cfn-service-create
type: single
command:
openstack endpoint create --region RegionOne cloudformation public {{ address('heat-api-cfn', heat.api_cfn_port, external=True, with_scheme=True) }}/v1
- name: heat-cfn-internal-endpoint-create
dependencies:
- heat-cfn-service-create
type: single
command:
openstack endpoint create --region RegionOne cloudformation internal {{ address('heat-api-cfn', heat.api_cfn_port, with_scheme=True) }}/v1
- name: heat-cfn-admin-endpoint-create
dependencies:
- heat-cfn-service-create
type: single
command:
openstack endpoint create --region RegionOne cloudformation admin {{ address('heat-api-cfn', heat.api_cfn_port, with_scheme=True) }}/v1
daemon:
dependencies:
- rpc
# heat-api in dependencies, because it prepares DB, which will be used
- heat-api
files:
- heat-conf
command: heat-api-cfn --config-file /etc/heat/heat.conf
# {% if heat.tls.enabled %}
- name: nginx-heat-api-cfn
image: nginx
daemon:
files:
- upstreams
- servers
- server-cert
- server-key
command: nginx
# {% endif %}
files:
heat-conf:
path: /etc/heat/heat.conf
content: heat.conf.j2
# {% if heat.tls.enabled %}
servers:
path: /etc/nginx/conf.d/servers.conf
content: nginx-api-cfn.conf.j2
perm: "0400"
upstreams:
path: /etc/nginx/conf.d/upstreams.conf
content: upstreams.conf.j2
perm: "0400"
server-cert:
path: /opt/ccp/etc/tls/server-cert.pem
content: server-cert.pem.j2
perm: "0400"
server-key:
path: /opt/ccp/etc/tls/server-key.pem
content: server-key.pem.j2
perm: "0400"
# {% endif %}