Zack Williams | 4e5e0cc | 2016-03-10 12:51:35 -0700 | [diff] [blame] | 1 | --- |
| 2 | # file: roles/dell-virt/prep/tasks/main.yml |
| 3 | |
| 4 | - name: Trust the Dell apt repository |
| 5 | apt_key: |
| 6 | keyserver=pool.sks-keyservers.net |
| 7 | id=1285491434D8786F |
| 8 | |
| 9 | - name: Add Dell apt repo |
Zack Williams | a091260 | 2016-03-14 11:05:09 -0700 | [diff] [blame] | 10 | apt_repository: |
Zack Williams | 4e5e0cc | 2016-03-10 12:51:35 -0700 | [diff] [blame] | 11 | repo="deb http://linux.dell.com/repo/community/{{ ansible_distribution | lower }} {{ ansible_distribution_release }} openmanage" |
| 12 | |
| 13 | - name: Install BIOS configuration scripts |
| 14 | apt: |
| 15 | update_cache=yes |
Zack Williams | 6c3b873 | 2016-03-15 09:57:07 -0700 | [diff] [blame] | 16 | cache_valid_time=3600 |
Zack Williams | 4e5e0cc | 2016-03-10 12:51:35 -0700 | [diff] [blame] | 17 | name=dtk-scripts |
| 18 | |
| 19 | # KVM virtualization is either "kvm_intel" or "kvm_amd" on amd64 |
| 20 | - name: Check to see if processor KVM virtualization module loaded in kernel |
| 21 | shell: lsmod | grep kvm_ |
| 22 | ignore_errors: true |
| 23 | register: virtualization_enabled |
Zack Williams | 3562456 | 2016-08-28 17:12:26 -0700 | [diff] [blame] | 24 | tags: |
| 25 | - skip_ansible_lint # just used to register result |
Zack Williams | 4e5e0cc | 2016-03-10 12:51:35 -0700 | [diff] [blame] | 26 | |
| 27 | - name: Enable virtualization in BIOS |
| 28 | command: /opt/dell/toolkit/bin/syscfg --virtualization=enable |
| 29 | when: virtualization_enabled|failed |
| 30 | |