On Github steveb / heat-lca
Steve Baker / sbaker@redhat.com / @stevebake
Heat is a REST service for the declarative orchestration of multi-tenant OpenStack cloud services.
Heat Kubernetes is a REST service for the declarative orchestration of multi-tenant OpenStack cloud services containers.
Processes a container manifest so the containers are launched according to how they are described.
heat_template_version: 2014-10-16
parameters:
key_name:
type: string
resources:
server:
type: OS::Nova::Server
properties:
image: Fedora-x86_64-20-20140618-sda
flavor: m1.small
key_name: {get_param: key_name}
outputs:
server_ip:
value: {get_attr: [server, first_address]}
# heat-base-standalone/Dockerfile FROM fedora:20 MAINTAINER Steve Baker <steve@stevebaker.org> ADD heat /opt/heat ADD install-heat.sh /opt/install-heat.sh RUN /opt/install-heat.sh ADD config-heat.sh /opt/heat/config-heat.sh # heat-api-standalone/Dockerfile FROM stevebake/heat-base-standalone MAINTAINER Steve Baker <steve@stevebaker.org> ADD ./start.sh /start.sh CMD ["/start.sh"]
“...the code responsible for downloading images is shockingly insecure. Users should only download images whose provenance is without question. At present, this does not include “trusted” images hosted by Docker, Inc” - Jonathan Rudenberg
“...one of the most important ways you can protect yourself when using Docker images is to make sure you only use content from a source you trust and to separate the download and unpack/install steps. The easiest way to do this is simply to not use “docker pull” command.” - Trevor Jay
https://securityblog.redhat.com/2014/12/18/before-you-initiate-a-docker-pull/
resources:
heat_pod_config:
type: OS::Heat::StructuredConfig
properties:
group: kubelet
config:
version: v1beta2
containers:
- name: rabbitmq
image: {get_input: rabbitmq_image}
ports:
- containerPort: 5672
hostPort: 5672
- name: mariadb
image: {get_input: mariadb_image}
ports:
- containerPort: 3306
hostPort: 3306
env:
- name: DB_ROOT_PASSWORD
value: {get_input: mariadb_password}
volumeMounts:
- name: mariadb-data
mountPath: /var/lib/mysql
- name: heat-engine
image: {get_input: heat_engine_image}
env:
- name: RABBIT_PASSWORD
value: guest
- name: DB_ROOT_PASSWORD
value: {get_input: mariadb_password}
- name: HEAT_DB_PASSWORD
value: {get_input: heatdb_password}
- name: KEYSTONE_PUBLIC_SERVICE_HOST
value: {get_input: keystone_host}
- name: AUTH_ENCRYPTION_KEY
value: {get_input: heat_auth_encryption_key}
- name: HEAT_API_SERVICE_HOST
value: {get_input: heat_api_service_host}
- name: OS_AUTH_URL
value: {get_input: os_auth_url}
- name: heat-api
image: {get_input: heat_api_image}
ports:
- containerPort: 8004
hostPort: 8004
env:
- name: RABBIT_PASSWORD
value: guest
- name: DB_ROOT_PASSWORD
value: {get_input: mariadb_password}
- name: HEAT_DB_PASSWORD
value: {get_input: heatdb_password}
- name: KEYSTONE_PUBLIC_SERVICE_HOST
value: {get_input: keystone_host}
- name: AUTH_ENCRYPTION_KEY
value: {get_input: heat_auth_encryption_key}
- name: HEAT_API_SERVICE_HOST
value: {get_input: heat_api_service_host}
- name: OS_AUTH_URL
value: {get_input: os_auth_url}
volumes:
- name: mariadb-data
heat_pod_deployment:
type: OS::Heat::StructuredDeployment
properties:
name: 20_kubelet_deployment
config:
get_resource: heat_pod_config
server:
get_resource: server
input_values:
mariadb_image: {get_param: mariadb_image}
mariadb_password: {get_resource: mariadb_password}
rabbitmq_image: {get_param: rabbitmq_image}
heat_api_image: {get_param: heat_api_image}
heat_engine_image: {get_param: heat_engine_image}
heatdb_password: {get_resource: heatdb_password}
heat_auth_encryption_key: {get_resource: heat_auth_encryption_key}
heat_api_service_host: {get_attr: [server, first_address]}
os_auth_url: {get_param: os_auth_url}
Steve Baker / sbaker@redhat.com / @stevebake