Add storing introspection data in database option

Ironic-inspector database is a default config for
our devstack deploy. Sometimes we won't to use Swift,
and directly use database for store data.

This patch adds a variable for introspection
store_data.

Depends-On: https://review.opendev.org/#/c/658238/
Change-Id: I6a8888b778f517bee49705ee74463ae39b2b9163
changes/70/657770/6
Dongcan Ye 3 years ago
parent 72bd8cec3b
commit b8d1bda4c6
  1. 6
      devstack/example.local.conf
  2. 5
      devstack/plugin.sh
  3. 1
      zuul.d/ironic-inspector-jobs.yaml

@ -13,7 +13,11 @@ SWIFT_TEMPURL_KEY=$ADMIN_PASSWORD
disable_service n-net n-novnc
enable_service neutron q-svc q-agt q-dhcp q-l3 q-meta
# Enable Swift for storing introspection data
# Use ironic-inspector database as the introspection data backend, if needed.
#IRONIC_INSPECTOR_INTROSPECTION_DATA_STORE=database
# Enable Swift for storing introspection data, these services
# can be disabled if introspection data store is set to database.
enable_service s-proxy s-object s-container s-account
# Enable Ironic, Ironic Inspector plugins

@ -64,6 +64,7 @@ IRONIC_INSPECTOR_NODE_NOT_FOUND_HOOK=${IRONIC_INSPECTOR_NODE_NOT_FOUND_HOOK:-""}
IRONIC_INSPECTOR_OVS_PORT=${IRONIC_INSPECTOR_OVS_PORT:-brbm-inspector}
IRONIC_INSPECTOR_EXTRA_KERNEL_CMDLINE=${IRONIC_INSPECTOR_EXTRA_KERNEL_CMDLINE:-""}
IRONIC_INSPECTOR_POWER_OFF=${IRONIC_INSPECTOR_POWER_OFF:-True}
IRONIC_INSPECTOR_INTROSPECTION_DATA_STORE=${IRONIC_INSPECTOR_INTROSPECTION_DATA_STORE:-swift}
GITDIR["python-ironic-inspector-client"]=$DEST/python-ironic-inspector-client
GITREPO["python-ironic-inspector-client"]=${IRONIC_INSPECTOR_CLIENT_REPO:-${GIT_BASE}/openstack/python-ironic-inspector-client.git}
GITBRANCH["python-ironic-inspector-client"]=${IRONIC_INSPECTOR_CLIENT_BRANCH:-master}
@ -277,6 +278,8 @@ function configure_inspector {
configure_inspector_swift
fi
inspector_iniset processing store_data $IRONIC_INSPECTOR_INTROSPECTION_DATA_STORE
iniset "$IRONIC_CONF_FILE" inspector enabled True
iniset "$IRONIC_CONF_FILE" inspector service_url $IRONIC_INSPECTOR_URI
@ -319,7 +322,6 @@ function configure_inspector {
function configure_inspector_swift {
inspector_configure_auth_for swift
inspector_iniset processing store_data swift
}
function configure_inspector_dhcp {
@ -449,6 +451,7 @@ elif [[ "$1" == "stack" && "$2" == "test-config" ]]; then
iniset $TEMPEST_CONFIG baremetal_introspection auto_discovery_default_driver fake-hardware
iniset $TEMPEST_CONFIG baremetal_introspection auto_discovery_target_driver ipmi
fi
iniset $TEMPEST_CONFIG baremetal_introspection data_store $IRONIC_INSPECTOR_INTROSPECTION_DATA_STORE
fi
fi

@ -62,3 +62,4 @@
IRONIC_IPXE_ENABLED: True
IRONIC_INSPECTOR_RAMDISK_ELEMENT: ironic-agent
IRONIC_INSPECTOR_DHCP_FILTER: dnsmasq
IRONIC_INSPECTOR_INTROSPECTION_DATA_STORE: database

Loading…
Cancel
Save