Pluggable modules

Configure and use OneFuse Pluggable Modules with the Python module

To learn more about this OneFuse module, refer to Pluggable modules.

Prerequisites

  1. Configure OneFuse Manager
  2. Review an overview on OneFuse Modules with OneFuse Python Module

Provision

Run provisioning scenarios configured on the OneFuse Pluggable Module Policy for a resource.

Method

#Run the following in the Python Console
#Assumes OneFuse Manager is instantiated to 'ofm' variable

ofm.provision_module('<policy_name>', <template_properties>, '<tracking_id>')

Parameter references

The following defines the function of each Pluggable Module specific parameters.

Parameter Name Required? Notes
policy_name Required OneFuse Module Policy Name (string).
template_properties Optional Additional properties that are referenced within the Policy. Python dict format.
tracking_id Optional Tracking ID (string) to link multiple OneFuse Policy Executions and resulting OneFuse Managed Objects together. If none is passed, one gets generated by OneFuse for that specific Policy Execution. See the tracking ID methods below.

OneFuse Python Module Tracking ID methods

Method Name Notes
create_tracking_id() Generate a unique Tracking ID to link OneFuse Policy Executions and the resulting Managed Objects together.
get_tracking_id_from_mo('<Path to OneFuse Managed Object>') Get the Tracking ID from a OneFuse Managed Object.
add_tracking_id_to_headers('<Tracking ID>') Add Tracking ID into request headers. When making custom requests to OneFuse instead of using OneFuse Python Module methods provided.

Learn more about OneFuse Tracking ID.

Deprovision

Run deprovisioning scenarios, if configured on the OneFuse Pluggable Module Policy, for a resource.

Method

#Run the following in the Python Console
#Assumes OneFuse Manager is instantiated to 'ofm' variable

ofm.deprovision_module('<mo_id>')

Parameter references

The following defines the function of the method parameter.

Parameter Name Required? Notes
mo_id Required ID of the OneFuse Pluggable Module Deployment Managed Object.

Other methods

#Run the following in the Python Console

## upload_pluggable_module
#  Upload a new Pluggable Module to OneFuse
#  Run the following help command to learn more
help(OneFuseManager.upload_pluggable_module)

## export_pluggable_module
#  Export an existing Pluggable Module from OneFuse
#  Run the following help command to learn more
help(OneFuseManager.export_pluggable_module)