1 # ============LICENSE_START==========================================
2 # ===================================================================
3 # Copyright (c) 2017 AT&T
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
9 # http://www.apache.org/licenses/LICENSE-2.0
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
16 #============LICENSE_END============================================
18 # this is the cloud init. It will install the reqiured packages and do some basic config on every VM.
22 cloudify_host_cloud_config:
23 type: cloudify.nodes.CloudInit.CloudConfig
29 - name: { get_input: agent_user }
33 sudo: ['ALL=(ALL) NOPASSWD:ALL']
35 - { get_secret: agent_key_public }
37 - path: /etc/yum.repos.d/kubernetes.repo
41 # installed by cloud-init
44 baseurl=https://packages.cloud.google.com/yum/repos/kubernetes-el7-x86_64
48 gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg
49 https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg
51 - path: /etc/sysctl.d/k8s.conf
55 # installed by cloud-init
56 net.bridge.bridge-nf-call-ip6tables = 1
57 net.bridge.bridge-nf-call-iptables = 1
64 - [kubernetes-cni, 0.5.1-1]
68 - [ sysctl , '--system' ]
69 - [ systemctl, enable, docker ]
70 - [ systemctl, start, docker ]
71 - [ systemctl, enable, kubelet ]
72 - [ systemctl, start, kubelet ]
73 - [ mkdir, '-p', /tmp/data ]
74 - [ chcon, '-Rt', svirt_sandbox_file_t, /tmp/data ]
75 - [ mkdir, '-p', /dockerdata-nfs ]
76 - [ chmod, 777, /dockerdata-nfs ]