summaryrefslogtreecommitdiff
path: root/tasks/prepare.yml
blob: ef40aa1cfa5721b96a7244733ccafba41904d4a5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
---
- name: Subscribe to rhel-7-server-cert-rpms
  become: True
  shell: subscription-manager repos --enable=rhel-7-server-cert-rpms
  register: rhsm
  until: rhsm.rc == 0
  retries: 5
  delay: 10
  when: openstack_certification_enable_rhsm_repo

- name: Copy an openstack certification repository
  become: True
  copy:
    src: "{{ openstack_certification_repo_file }}"
    dest: /etc/yum.repos.d/{{ openstack_certification_repo_file | basename }}
  when: openstack_certification_repo_file is defined

- name: Install Red Hat certification packages
  become: True
  package:
    name: '{{ item }}'
    state: present
  with_items: "{{ openstack_certification_install_rpms }}"