use docker repository to install on CentOS
This commit is contained in:
parent
936927a54f
commit
48a85ce8f8
4 changed files with 13 additions and 18 deletions
|
@ -91,6 +91,11 @@ matrix:
|
||||||
allow_failures:
|
allow_failures:
|
||||||
- env: KUBE_NETWORK_PLUGIN=weave CLOUD_IMAGE=ubuntu-1404-trusty CLOUD_REGION=asia-east1-c
|
- env: KUBE_NETWORK_PLUGIN=weave CLOUD_IMAGE=ubuntu-1404-trusty CLOUD_REGION=asia-east1-c
|
||||||
- env: KUBE_NETWORK_PLUGIN=calico CLOUD_IMAGE=ubuntu-1404-trusty CLOUD_REGION=us-east1-d
|
- env: KUBE_NETWORK_PLUGIN=calico CLOUD_IMAGE=ubuntu-1404-trusty CLOUD_REGION=us-east1-d
|
||||||
|
# Issue with Weave #177 to be fixed
|
||||||
|
- env: KUBE_NETWORK_PLUGIN=weave CLOUD_IMAGE=debian-8-kubespray CLOUD_REGION=us-east1-d
|
||||||
|
- env: KUBE_NETWORK_PLUGIN=weave CLOUD_IMAGE=centos-7-sudo CLOUD_REGION=us-central1-c
|
||||||
|
- env: KUBE_NETWORK_PLUGIN=weave CLOUD_IMAGE=rhel-7-sudo CLOUD_REGION=europe-west1-b
|
||||||
|
- env: KUBE_NETWORK_PLUGIN=weave CLOUD_IMAGE=ubuntu-1510-wily CLOUD_REGION=us-east1-d
|
||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
# Install Ansible.
|
# Install Ansible.
|
||||||
|
|
|
@ -38,12 +38,12 @@
|
||||||
with_items: "{{ docker_repo_info.repos }}"
|
with_items: "{{ docker_repo_info.repos }}"
|
||||||
when: docker_repo_info.repos|length > 0
|
when: docker_repo_info.repos|length > 0
|
||||||
|
|
||||||
- name: Configure docker repository on RedHat
|
- name: Configure docker repository on RedHat/CentOS
|
||||||
copy:
|
copy:
|
||||||
src: "rh_docker.repo"
|
src: "rh_docker.repo"
|
||||||
dest: "/etc/yum.repos.d/docker.repo"
|
dest: "/etc/yum.repos.d/docker.repo"
|
||||||
when: ansible_distribution == "RedHat" and
|
when: ansible_distribution in ["CentOS","RedHat"] and
|
||||||
ansible_distribution_major_version > 7
|
ansible_distribution_major_version >= 7
|
||||||
|
|
||||||
- name: ensure docker packages are installed
|
- name: ensure docker packages are installed
|
||||||
action: "{{ docker_package_info.pkg_mgr }}"
|
action: "{{ docker_package_info.pkg_mgr }}"
|
||||||
|
@ -53,15 +53,6 @@
|
||||||
with_items: "{{ docker_package_info.pkgs }}"
|
with_items: "{{ docker_package_info.pkgs }}"
|
||||||
when: docker_package_info.pkgs|length > 0
|
when: docker_package_info.pkgs|length > 0
|
||||||
|
|
||||||
- name: Centos needs xfs storage type for devicemapper if used
|
|
||||||
lineinfile:
|
|
||||||
dest: /etc/sysconfig/docker-storage
|
|
||||||
line: "DOCKER_STORAGE_OPTIONS='--storage-opt dm.fs=xfs'"
|
|
||||||
regexp: '^DOCKER_STORAGE_OPTIONS=.*$'
|
|
||||||
state: present
|
|
||||||
backup: yes
|
|
||||||
when: ansible_distribution == "CentOS"
|
|
||||||
|
|
||||||
- meta: flush_handlers
|
- meta: flush_handlers
|
||||||
|
|
||||||
- name: ensure docker service is started and enabled
|
- name: ensure docker service is started and enabled
|
||||||
|
|
|
@ -79,11 +79,10 @@
|
||||||
changed_when: False
|
changed_when: False
|
||||||
|
|
||||||
- name: Install epel-release on RedHat/CentOS
|
- name: Install epel-release on RedHat/CentOS
|
||||||
action:
|
command: rpm -ivh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
|
||||||
module: "{{ ansible_pkg_mgr }}"
|
when: ansible_distribution in ["CentOS","RedHat"] and
|
||||||
name: "epel-release"
|
ansible_distribution_major_version >= 7
|
||||||
state: latest
|
changed_when: False
|
||||||
when: ansible_distribution in ['CentOS', 'RedHat']
|
|
||||||
|
|
||||||
- name: Install packages requirements
|
- name: Install packages requirements
|
||||||
action:
|
action:
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
- name: "Check certs | check if the certs have already been generated on first master"
|
- name: "Check certs | check if the certs have already been generated on first master"
|
||||||
stat:
|
stat:
|
||||||
path: "{{ kube_cert_dir }}/ca.pem"
|
path: "{{ kube_cert_dir }}/ca.pem"
|
||||||
delegate_to: groups['kube-master'][0]
|
delegate_to: "{{groups['kube-master'][0]}}"
|
||||||
register: kubecert_master
|
register: kubecert_master
|
||||||
run_once: true
|
run_once: true
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue