Merge "Derive Pci passthrough whitelist disable option" into stable/stein

This commit is contained in:
Zuul 2019-12-05 16:31:44 +00:00 committed by Gerrit Code Review
commit 9cb5d3a030
1 changed files with 33 additions and 14 deletions

View File

@ -83,6 +83,21 @@ parameters:
default: 5672
description: The network port for messaging backend
type: number
DerivePciWhitelistEnabled:
default: true
description: Whether to enable or not the pci passthrough whitelist automation.
type: boolean
tags:
- role_specific
conditions:
derive_pci_whitelist_enabled:
or:
- and:
- equals: [{get_param: DerivePciWhitelistEnabled}, true]
- equals: [{get_param: [RoleParameters, DerivePciWhitelistEnabled]}, '']
- equals: [{get_param: [RoleParameters, DerivePciWhitelistEnabled]}, true]
resources:
@ -195,20 +210,24 @@ outputs:
name: virt_sandbox_use_netlink
persistent: yes
state: yes
- name: "creating directory"
file:
state: directory
path: /var/lib/pci_passthrough_whitelist_scripts
owner: root
group: root
mode: 0750
- name: derive pci passthrough whitelist
copy:
content: {get_file: ./derive_pci_passthrough_whitelist.py}
dest: '/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py'
mode: 0700
- name: run derive_pci_passthrough_whitelist.py
command: /var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py
-
if:
- derive_pci_whitelist_enabled
- - name: "creating directory"
file:
state: directory
path: /var/lib/pci_passthrough_whitelist_scripts
owner: root
group: root
mode: 0750
- name: derive pci passthrough whitelist
copy:
content: {get_file: ./derive_pci_passthrough_whitelist.py}
dest: '/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py'
mode: 0700
- name: run derive_pci_passthrough_whitelist.py
command: /var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py
- []
metadata_settings:
get_attr: [NeutronBase, role_data, metadata_settings]
upgrade_tasks: []