Python packages for ansible (py2.x) were missing causing ansible to
fail. This patch adds those packages to the ISO and deploy
dependencies playbook. Also includes fixes for deploy_dependencies
playbook for virt resources to make them idempotent by removing
using 'command' and instead just declaring 'state'.
Change-Id: I9311184a6f3c40ead0a8ba16fa0b61667876cf12
Signed-off-by: Tim Rozet <trozet@redhat.com>
@ln $(RPMUDR) $(BUILD_DIR)/centos/Packages
@ln $(RPMODL) $(BUILD_DIR)/centos/Packages
# add packages to the centos packages
@ln $(RPMUDR) $(BUILD_DIR)/centos/Packages
@ln $(RPMODL) $(BUILD_DIR)/centos/Packages
# add packages to the centos packages
- cd $(BUILD_DIR)/centos/Packages && yumdownloader openvswitch jq python34 python34-libs python34-PyYAML python34-setuptools ipxe-roms-qemu python34-jinja2 python34-markupsafe ansible python34-six python34-cffi python34-idna python34-pycparser python-crypto python-httplib2 python-jinja2 python-keyczar python-paramiko sshpass python-ecdsa python34-ply
+ cd $(BUILD_DIR)/centos/Packages && yumdownloader openvswitch jq python34 python34-libs python34-PyYAML python34-setuptools
+ cd $(BUILD_DIR)/centos/Packages && yumdownloader python34-jinja2 python34-markupsafe ansible python34-six python34-cffi
+ cd $(BUILD_DIR)/centos/Packages && yumdownloader ipxe-roms-qemu python34-idna python34-pycparser python-crypto python-httplib2
+ cd $(BUILD_DIR)/centos/Packages && yumdownloader python-jinja2 python-keyczar python-paramiko sshpass python-ecdsa python34-ply
+ cd $(BUILD_DIR)/centos/Packages && yumdownloader libvirt-python python-lxml
cd $(BUILD_DIR)/centos/Packages && curl -O http://artifacts.opnfv.org/apex/dependencies/python3-ipmi-0.3.0-1.noarch.rpm
cd $(BUILD_DIR)/centos/Packages && curl -O http://artifacts.opnfv.org/apex/dependencies/python34-asn1crypto-0.22.0-1.el7.centos.noarch.rpm
cd $(BUILD_DIR)/centos/Packages && curl -O http://artifacts.opnfv.org/apex/dependencies/python34-cryptography-2.0.3-1.el7.centos.x86_64.rpm
cd $(BUILD_DIR)/centos/Packages && curl -O http://artifacts.opnfv.org/apex/dependencies/python3-ipmi-0.3.0-1.noarch.rpm
cd $(BUILD_DIR)/centos/Packages && curl -O http://artifacts.opnfv.org/apex/dependencies/python34-asn1crypto-0.22.0-1.el7.centos.noarch.rpm
cd $(BUILD_DIR)/centos/Packages && curl -O http://artifacts.opnfv.org/apex/dependencies/python34-cryptography-2.0.3-1.el7.centos.x86_64.rpm
---
- hosts: localhost
tasks:
---
- hosts: localhost
tasks:
+ - yum:
+ name: "{{ item }}"
+ state: present
+ with_items:
+ - python-lxml
+ - libvirt-python
- sysctl:
name: net.ipv4.ip_forward
state: present
- sysctl:
name: net.ipv4.ip_forward
state: present
state: present
with_items: '{{ virsh_enabled_networks }}'
- virt_net:
state: present
with_items: '{{ virsh_enabled_networks }}'
- virt_net:
name: '{{ item }}'
xml: '{{ lookup("template", "virsh_network_ovs.xml.j2") }}'
name: '{{ item }}'
xml: '{{ lookup("template", "virsh_network_ovs.xml.j2") }}'
with_items: '{{ virsh_enabled_networks }}'
- virt_net:
with_items: '{{ virsh_enabled_networks }}'
- virt_net:
with_items: '{{ virsh_enabled_networks }}'
- virt_pool:
name: default
with_items: '{{ virsh_enabled_networks }}'
- virt_pool:
name: default
xml: '{{ lookup("template", "virsh_pool.xml.j2") }}'
xml: '{{ lookup("template", "virsh_pool.xml.j2") }}'
+ - virt_pool:
+ name: default
+ autostart: yes
+ state: active
- lineinfile:
path: /etc/modprobe.d/kvm_intel.conf
line: 'options kvm-intel nested=1'
- lineinfile:
path: /etc/modprobe.d/kvm_intel.conf
line: 'options kvm-intel nested=1'