From e9ab77f5492aab6bce403617fe92cb0a14aaa563 Mon Sep 17 00:00:00 2001 From: charliemordant Date: Mon, 6 Apr 2020 00:25:45 +0200 Subject: [PATCH 1/2] Docker fedora 31 support Tested docker install over Fedora 31 --- roles/docker/meta/main.yml | 2 +- .../molecule/vagrant-fedora-31/molecule.yml | 28 +++++++++++++++++++ roles/docker/tasks/main.yml | 2 +- 3 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 roles/docker/molecule/vagrant-fedora-31/molecule.yml diff --git a/roles/docker/meta/main.yml b/roles/docker/meta/main.yml index ddb5cf6..7d3eb08 100644 --- a/roles/docker/meta/main.yml +++ b/roles/docker/meta/main.yml @@ -12,8 +12,8 @@ galaxy_info: platforms: - name: Fedora versions: - - all - 30 + - 31 - name: EL versions: - 7 diff --git a/roles/docker/molecule/vagrant-fedora-31/molecule.yml b/roles/docker/molecule/vagrant-fedora-31/molecule.yml new file mode 100644 index 0000000..d3b0ca5 --- /dev/null +++ b/roles/docker/molecule/vagrant-fedora-31/molecule.yml @@ -0,0 +1,28 @@ +--- +dependency: + name: galaxy + role-file: requirements.yml +driver: + name: vagrant + provider: + name: virtualbox +lint: + name: yamllint +platforms: + - name: docker-fedora-31 + box: fedora/31-cloud-base +provisioner: + name: ansible + log: True + playbooks: + vagrant: + prepare: ../resources/playbooks/prepare.yml + converge: ../resources/playbooks/playbook.yml + verify: ../resources/playbooks/verify.yml + lint: + name: ansible-lint +verifier: + name: goss + directory: ../resources/tests + lint: + name: yamllint diff --git a/roles/docker/tasks/main.yml b/roles/docker/tasks/main.yml index 42ffad5..6f4bff1 100644 --- a/roles/docker/tasks/main.yml +++ b/roles/docker/tasks/main.yml @@ -5,7 +5,7 @@ when: ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_version']|int <= 7 - include: install_Fedora.yml - when: ansible_facts['distribution'] == "Fedora" and ansible_facts['distribution_version']|int == 30 + when: ansible_facts['distribution'] == "Fedora" and ansible_facts['distribution_version']|int >= 30 - include: install_Ubuntu.yml when: ansible_facts['distribution'] == "Ubuntu" and ansible_facts['distribution_version'] == "18.04" From 240735de5b128dd1c34bac27848e7565ae87ef69 Mon Sep 17 00:00:00 2001 From: Charlie Mordant Date: Sat, 11 Apr 2020 14:42:17 +0200 Subject: [PATCH 2/2] update repository and sha Use fedora repository installation instead of centos for fedora --- roles/docker/tasks/install_Fedora.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roles/docker/tasks/install_Fedora.yml b/roles/docker/tasks/install_Fedora.yml index b3abe6c..40ae66c 100644 --- a/roles/docker/tasks/install_Fedora.yml +++ b/roles/docker/tasks/install_Fedora.yml @@ -12,8 +12,8 @@ - name: Setup yum repository get_url: - url: https://download.docker.com/linux/centos/docker-ce.repo - checksum: "sha256:6650718e0fe5202ae7618521f695d43a8bc051c539d7570f0edbfa5b4916f218" + url: https://download.docker.com/linux/fedora/docker-ce.repo + checksum: "sha256:3af973c1f2e16a032a11074eb22b440894ad4936c9ca86b666f8cf8342b7bea7" dest: /etc/yum.repos.d/docker-ce.repo mode: '0644' become: yes