From de19339a7d5fd4c68c1254476c5e9d909948b258 Mon Sep 17 00:00:00 2001 From: Fayaaz Ahmed Date: Mon, 25 Apr 2016 11:06:06 +0100 Subject: [PATCH] Added updates repos for CentOS --- roles/spacewalk-customisations/defaults/main.yml | 8 ++++++-- roles/spacewalk-customisations/tasks/customisations.yml | 4 ++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/roles/spacewalk-customisations/defaults/main.yml b/roles/spacewalk-customisations/defaults/main.yml index 37c04a8..946c132 100755 --- a/roles/spacewalk-customisations/defaults/main.yml +++ b/roles/spacewalk-customisations/defaults/main.yml @@ -23,8 +23,12 @@ spacewalk_repo_info: - {name: 'CentOS_7', label: 'centos-7', repo: 'CentOS_7', repo_url: 'http://mirror.ox.ac.uk/sites/mirror.centos.org/7/os/x86_64/', arch: 'x86_64', checksum: 'sha256'} spacewalk_child_repo_info: - - {name: 'CentOS_7_epel', label: 'centos-7-epel', parent: 'centos-7', repo: 'CentOS_7_epel', repo_url: 'http://anorien.csc.warwick.ac.uk/mirrors/epel/7/x86_64/', arch: 'x86_64', checksum: 'sha256'} - - {name: 'CentOS_6_epel', label: 'centos-6-epel', parent: 'centos-6', repo: 'CentOS_6_epel', repo_url: 'http://anorien.csc.warwick.ac.uk/mirrors/epel/6/x86_64/', arch: 'x86_64', checksum: 'sha256'} + - {name: 'CentOS_7_epel', label: 'centos-7-epel', parent: 'centos-7', repo: 'CentOS_7_epel', activationkey: '1-centos-7-epel', repo_url: 'http://anorien.csc.warwick.ac.uk/mirrors/epel/7/x86_64/', arch: 'x86_64', checksum: 'sha256'} + - {name: 'CentOS_6_epel', label: 'centos-6-epel', parent: 'centos-6', repo: 'CentOS_6_epel', activationkey: '1-centos-6-epel', repo_url: 'http://anorien.csc.warwick.ac.uk/mirrors/epel/6/x86_64/', arch: 'x86_64', checksum: 'sha256'} + - {name: 'CentOS_6_updates', label: 'centos-6-updates', parent: 'centos-6', repo: 'CentOS_6_updates', activationkey: '1-centos-6-epel', repo_url: 'http://mirror.centos.org/centos/6/updates/x86_64/', arch: 'x86_64', checksum: 'sha256'} + - {name: 'CentOS_7_updates', label: 'centos-7-updates', parent: 'centos-7', repo: 'CentOS_7_updates', activationkey: '1-centos-7-epel', repo_url: 'http://mirror.centos.org/centos/7/updates/x86_64/', arch: 'x86_64', checksum: 'sha256'} + - {name: 'CentOS_6_extras', label: 'centos-6-extras', parent: 'centos-6', repo: 'CentOS_6_extras', activationkey: '1-centos-6-epel', repo_url: 'http://mirror.centos.org/centos/6/extras/x86_64/', arch: 'x86_64', checksum: 'sha256'} + - {name: 'CentOS_7_extras', label: 'centos-7-extras', parent: 'centos-7', repo: 'CentOS_7_extras', activationkey: '1-centos-7-epel', repo_url: 'http://mirror.centos.org/centos/7/extras/x86_64/', arch: 'x86_64', checksum: 'sha256'} spacewalk_deb_repo_info: - {name: 'Ubuntu_Trusty_14_04', label: 'ubuntu-1404', repo: 'Ubuntu1404', repo_url: 'http://de.archive.ubuntu.com/ubuntu/dists/trusty/main/binary-amd64/', arch: 'amd64-deb', checksum: 'sha256'} diff --git a/roles/spacewalk-customisations/tasks/customisations.yml b/roles/spacewalk-customisations/tasks/customisations.yml index 8e41ef1..73efdec 100644 --- a/roles/spacewalk-customisations/tasks/customisations.yml +++ b/roles/spacewalk-customisations/tasks/customisations.yml @@ -32,11 +32,11 @@ with_items: "{{ spacewalk_repo_info | union(spacewalk_child_repo_info) }}" - name: Associate child channels with activationkeys - command: spacecmd --user=admin --password={{spacewalk_admin_password}} -- activationkey_addchildchannels 1-{{item.label}} {{item.label}} + command: spacecmd --user=admin --password={{spacewalk_admin_password}} -- activationkey_addchildchannels {{item.activationkey}} {{item.label}} ignore_errors: true with_items: "{{spacewalk_child_repo_info}}" - name: Set sync repo schedules command: spacecmd --user=admin --password={{spacewalk_admin_password}} -- softwarechannel_setsyncschedule {{item.label}} 0 30 3 ? * * - with_items: "{{spacewalk_repo_info}}" \ No newline at end of file + with_items: "{{ spacewalk_repo_info | union(spacewalk_child_repo_info) }}" \ No newline at end of file