Added Amazon Linux 2 support for deploying with docker (#5301)
This commit is contained in:
parent
db5040e6ea
commit
4f70da2731
2 changed files with 20 additions and 1 deletions
16
roles/container-engine/docker/vars/amazon.yml
Normal file
16
roles/container-engine/docker/vars/amazon.yml
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
---
|
||||||
|
docker_kernel_min_version: '0'
|
||||||
|
|
||||||
|
# https://docs.aws.amazon.com/en_us/AmazonECS/latest/developerguide/docker-basics.html
|
||||||
|
|
||||||
|
docker_versioned_pkg:
|
||||||
|
'latest': docker
|
||||||
|
'18.03': docker-18.03.1ce-5.amzn2
|
||||||
|
'18.06': docker-18.06.1ce-10.amzn2
|
||||||
|
|
||||||
|
docker_version: "latest"
|
||||||
|
|
||||||
|
docker_package_info:
|
||||||
|
pkg_mgr: yum
|
||||||
|
pkgs:
|
||||||
|
- name: "{{ docker_versioned_pkg[docker_version | string] }}"
|
|
@ -3,7 +3,9 @@
|
||||||
- name: Confirm selinux deployed
|
- name: Confirm selinux deployed
|
||||||
stat:
|
stat:
|
||||||
path: /etc/selinux/config
|
path: /etc/selinux/config
|
||||||
when: ansible_os_family == "RedHat"
|
when:
|
||||||
|
- ansible_os_family == "RedHat"
|
||||||
|
- "'Amazon' not in ansible_distribution"
|
||||||
register: slc
|
register: slc
|
||||||
|
|
||||||
- name: Set selinux policy
|
- name: Set selinux policy
|
||||||
|
@ -12,6 +14,7 @@
|
||||||
state: "{{ preinstall_selinux_state }}"
|
state: "{{ preinstall_selinux_state }}"
|
||||||
when:
|
when:
|
||||||
- ansible_os_family == "RedHat"
|
- ansible_os_family == "RedHat"
|
||||||
|
- "'Amazon' not in ansible_distribution"
|
||||||
- slc.stat.exists
|
- slc.stat.exists
|
||||||
changed_when: False
|
changed_when: False
|
||||||
tags:
|
tags:
|
||||||
|
|
Loading…
Reference in a new issue