123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102 |
- # Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
- #
- # Licensed under the Apache License, Version 2.0 (the "License");
- # you may not use this file except in compliance with the License.
- # You may obtain a copy of the License at
- #
- # http://www.apache.org/licenses/LICENSE-2.0
- #
- # Unless required by applicable law or agreed to in writing, software
- # distributed under the License is distributed on an "AS IS" BASIS,
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- # See the License for the specific language governing permissions and
- # limitations under the License.
- ---
- - name: add kubernetes repo
- copy: src=kubernetes.repo dest=/etc/yum.repos.d/ owner=root group=root mode=644
- tags: install
- # add ElRepo GPG Key
- - name: add ElRepo GPG Key
- rpm_key:
- state: present
- key: https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
- tags: install
- - name: add ElRepo (Nvidia kmod drivers)
- yum:
- name: http://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpm
- state: present
- tags: install
- - name: Add Docker Community Edition Repo
- get_url:
- url: https://download.docker.com/linux/centos/docker-ce.repo
- dest: /etc/yum.repos.d/docker-ce.repo
- - name: update sysctl to handle incorrectly routed traffic when iptables is bypassed
- copy: src=k8s.conf dest=/etc/sysctl.d/ owner=root group=root mode=644
- tags: install
- - name: update sysctl
- command: /sbin/sysctl --system
- tags: install
- - name: Install EPEL Repository
- yum: name=epel-release state=present
- tags: install
- - name: disable swap
- command: /sbin/swapoff -a
- tags: install
- - name: Disable SELinux
- selinux:
- state: disabled
- tags: install
- - name: install common packages
- package:
- name:
- - yum-plugin-versionlock
- - gcc
- - nfs-utils
- - python-pip
- - docker-ce
- - bash-completion
- - kubelet-1.16.7
- - kubeadm-1.16.7
- - kubectl-1.16.7
- - nvidia-detect
- state: present
- tags: install
- - name: versionlock kubernetes
- command: yum versionlock kubelet-1.16.7 kubectl-1.16.7 kubeadm-1.16.7
- tags: install
- - name: install InfiniBand Support
- package:
- name: "@Infiniband Support"
- state: present
- - name: upgrade pip
- command: /bin/pip install --upgrade pip
- tags: install
- - name: Start and Enable docker service
- service:
- name: docker
- state: restarted
- enabled: yes
- tags: install
- - name: Start and Enable Kubernetes - kubelet
- service:
- name: kubelet
- state: restarted
- enabled: yes
- tags: install
|