|
@@ -88,11 +88,6 @@ parameters:
|
|
label: Infra image
|
|
label: Infra image
|
|
description: Name of the image for the infra node servers
|
|
description: Name of the image for the infra node servers
|
|
|
|
|
|
- dns_image:
|
|
|
|
- type: string
|
|
|
|
- label: DNS image
|
|
|
|
- description: Name of the image for the DNS server
|
|
|
|
-
|
|
|
|
etcd_flavor:
|
|
etcd_flavor:
|
|
type: string
|
|
type: string
|
|
label: Etcd flavor
|
|
label: Etcd flavor
|
|
@@ -113,11 +108,6 @@ parameters:
|
|
label: Infra flavor
|
|
label: Infra flavor
|
|
description: Flavor of the infra node servers
|
|
description: Flavor of the infra node servers
|
|
|
|
|
|
- dns_flavor:
|
|
|
|
- type: string
|
|
|
|
- label: DNS flavor
|
|
|
|
- description: Flavor of the DNS server
|
|
|
|
-
|
|
|
|
outputs:
|
|
outputs:
|
|
|
|
|
|
etcd_names:
|
|
etcd_names:
|
|
@@ -168,26 +158,6 @@ outputs:
|
|
description: Floating IPs of the nodes
|
|
description: Floating IPs of the nodes
|
|
value: { get_attr: [ infra_nodes, floating_ip ] }
|
|
value: { get_attr: [ infra_nodes, floating_ip ] }
|
|
|
|
|
|
- dns_name:
|
|
|
|
- description: Name of the DNS
|
|
|
|
- value:
|
|
|
|
- get_attr:
|
|
|
|
- - dns
|
|
|
|
- - name
|
|
|
|
-
|
|
|
|
- dns_floating_ip:
|
|
|
|
- description: Floating IP of the DNS
|
|
|
|
- value:
|
|
|
|
- get_attr:
|
|
|
|
- - dns
|
|
|
|
- - addresses
|
|
|
|
- - str_replace:
|
|
|
|
- template: openshift-ansible-cluster_id-net
|
|
|
|
- params:
|
|
|
|
- cluster_id: { get_param: cluster_id }
|
|
|
|
- - 1
|
|
|
|
- - addr
|
|
|
|
-
|
|
|
|
resources:
|
|
resources:
|
|
|
|
|
|
net:
|
|
net:
|
|
@@ -213,22 +183,7 @@ resources:
|
|
template: subnet_24_prefix.0/24
|
|
template: subnet_24_prefix.0/24
|
|
params:
|
|
params:
|
|
subnet_24_prefix: { get_param: subnet_24_prefix }
|
|
subnet_24_prefix: { get_param: subnet_24_prefix }
|
|
- allocation_pools:
|
|
|
|
- - start:
|
|
|
|
- str_replace:
|
|
|
|
- template: subnet_24_prefix.3
|
|
|
|
- params:
|
|
|
|
- subnet_24_prefix: { get_param: subnet_24_prefix }
|
|
|
|
- end:
|
|
|
|
- str_replace:
|
|
|
|
- template: subnet_24_prefix.254
|
|
|
|
- params:
|
|
|
|
- subnet_24_prefix: { get_param: subnet_24_prefix }
|
|
|
|
- dns_nameservers:
|
|
|
|
- - str_replace:
|
|
|
|
- template: subnet_24_prefix.2
|
|
|
|
- params:
|
|
|
|
- subnet_24_prefix: { get_param: subnet_24_prefix }
|
|
|
|
|
|
+ dns_nameservers: { get_param: dns_nameservers }
|
|
|
|
|
|
router:
|
|
router:
|
|
type: OS::Neutron::Router
|
|
type: OS::Neutron::Router
|
|
@@ -428,44 +383,6 @@ resources:
|
|
port_range_min: 443
|
|
port_range_min: 443
|
|
port_range_max: 443
|
|
port_range_max: 443
|
|
|
|
|
|
- dns-secgrp:
|
|
|
|
- type: OS::Neutron::SecurityGroup
|
|
|
|
- properties:
|
|
|
|
- name:
|
|
|
|
- str_replace:
|
|
|
|
- template: openshift-ansible-cluster_id-dns-secgrp
|
|
|
|
- params:
|
|
|
|
- cluster_id: { get_param: cluster_id }
|
|
|
|
- description:
|
|
|
|
- str_replace:
|
|
|
|
- template: Security group for cluster_id cluster DNS
|
|
|
|
- params:
|
|
|
|
- cluster_id: { get_param: cluster_id }
|
|
|
|
- rules:
|
|
|
|
- - direction: ingress
|
|
|
|
- protocol: tcp
|
|
|
|
- port_range_min: 22
|
|
|
|
- port_range_max: 22
|
|
|
|
- remote_ip_prefix: { get_param: ssh_incoming }
|
|
|
|
- - direction: ingress
|
|
|
|
- protocol: udp
|
|
|
|
- port_range_min: 53
|
|
|
|
- port_range_max: 53
|
|
|
|
- remote_mode: remote_group_id
|
|
|
|
- remote_group_id: { get_resource: etcd-secgrp }
|
|
|
|
- - direction: ingress
|
|
|
|
- protocol: udp
|
|
|
|
- port_range_min: 53
|
|
|
|
- port_range_max: 53
|
|
|
|
- remote_mode: remote_group_id
|
|
|
|
- remote_group_id: { get_resource: master-secgrp }
|
|
|
|
- - direction: ingress
|
|
|
|
- protocol: udp
|
|
|
|
- port_range_min: 53
|
|
|
|
- port_range_max: 53
|
|
|
|
- remote_mode: remote_group_id
|
|
|
|
- remote_group_id: { get_resource: node-secgrp }
|
|
|
|
-
|
|
|
|
etcd:
|
|
etcd:
|
|
type: OS::Heat::ResourceGroup
|
|
type: OS::Heat::ResourceGroup
|
|
properties:
|
|
properties:
|
|
@@ -599,92 +516,3 @@ resources:
|
|
cluster_id: { get_param: cluster_id }
|
|
cluster_id: { get_param: cluster_id }
|
|
depends_on:
|
|
depends_on:
|
|
- interface
|
|
- interface
|
|
-
|
|
|
|
- dns:
|
|
|
|
- type: OS::Nova::Server
|
|
|
|
- properties:
|
|
|
|
- name:
|
|
|
|
- str_replace:
|
|
|
|
- template: cluster_id-dns
|
|
|
|
- params:
|
|
|
|
- cluster_id: { get_param: cluster_id }
|
|
|
|
- key_name: { get_resource: keypair }
|
|
|
|
- image: { get_param: dns_image }
|
|
|
|
- flavor: { get_param: dns_flavor }
|
|
|
|
- networks:
|
|
|
|
- - port: { get_resource: dns-port }
|
|
|
|
- user_data: { get_resource: dns-config }
|
|
|
|
- user_data_format: RAW
|
|
|
|
-
|
|
|
|
- dns-port:
|
|
|
|
- type: OS::Neutron::Port
|
|
|
|
- properties:
|
|
|
|
- network: { get_resource: net }
|
|
|
|
- fixed_ips:
|
|
|
|
- - subnet: { get_resource: subnet }
|
|
|
|
- ip_address:
|
|
|
|
- str_replace:
|
|
|
|
- template: subnet_24_prefix.2
|
|
|
|
- params:
|
|
|
|
- subnet_24_prefix: { get_param: subnet_24_prefix }
|
|
|
|
- security_groups:
|
|
|
|
- - { get_resource: dns-secgrp }
|
|
|
|
-
|
|
|
|
- dns-floating-ip:
|
|
|
|
- type: OS::Neutron::FloatingIP
|
|
|
|
- properties:
|
|
|
|
- floating_network: { get_param: external_net }
|
|
|
|
- port_id: { get_resource: dns-port }
|
|
|
|
-
|
|
|
|
- dns-config:
|
|
|
|
- type: OS::Heat::CloudConfig
|
|
|
|
- properties:
|
|
|
|
- cloud_config:
|
|
|
|
- disable_root: true
|
|
|
|
-
|
|
|
|
- hostname:
|
|
|
|
- str_replace:
|
|
|
|
- template: cluster_id-dns
|
|
|
|
- params:
|
|
|
|
- cluster_id: { get_param: cluster_id }
|
|
|
|
- fqdn:
|
|
|
|
- str_replace:
|
|
|
|
- template: cluster_id-dns.example.com
|
|
|
|
- params:
|
|
|
|
- cluster_id: { get_param: cluster_id }
|
|
|
|
-
|
|
|
|
- system_info:
|
|
|
|
- default_user:
|
|
|
|
- name: openshift
|
|
|
|
- sudo: ["ALL=(ALL) NOPASSWD: ALL"]
|
|
|
|
-
|
|
|
|
- write_files:
|
|
|
|
- - path: /etc/sudoers.d/00-openshift-no-requiretty
|
|
|
|
- permissions: 440
|
|
|
|
- # content: Defaults:openshift !requiretty
|
|
|
|
- # Encoded in base64 to be sure that we do not forget the trailing newline or
|
|
|
|
- # sudo will not be able to parse that file
|
|
|
|
- encoding: b64
|
|
|
|
- content: RGVmYXVsdHM6b3BlbnNoaWZ0ICFyZXF1aXJldHR5Cg==
|
|
|
|
- - path: /etc/sysconfig/network-scripts/ifcfg-eth0
|
|
|
|
- content:
|
|
|
|
- str_replace:
|
|
|
|
- template: |
|
|
|
|
- DEVICE="eth0"
|
|
|
|
- BOOTPROTO="dhcp"
|
|
|
|
- DNS1="$dns1"
|
|
|
|
- DNS2="$dns2"
|
|
|
|
- PEERDNS="no"
|
|
|
|
- ONBOOT="yes"
|
|
|
|
- params:
|
|
|
|
- $dns1:
|
|
|
|
- get_param:
|
|
|
|
- - dns_nameservers
|
|
|
|
- - 0
|
|
|
|
- $dns2:
|
|
|
|
- get_param:
|
|
|
|
- - dns_nameservers
|
|
|
|
- - 1
|
|
|
|
-
|
|
|
|
- runcmd:
|
|
|
|
- - [ "/usr/bin/systemctl", "restart", "network" ]
|
|
|