Hi, I'm new to Nutanix Playbooks,
We took trial version of NCM. I'm Trying to create a playbook that will add VMs in categories.
I tried to rely on the Githubs one but I didn't find something similar. both playbooks "autocategorize_new_vms" and "autocategorize_vms_by_os" have the same trigger event : Vms created
I'm looking for something that will run immediatly and add VMs in categories regardless of the power state.
I'm not able to add pkb files so here is the content of it :
{"pcVersion":"7.3","pcUuid":"856361a1-c11e-48c7-91c5-5fce7fb45103","hashValue":"rUlxGfGYe3x8ieHgdUj0CdJhv9xzRj/GPVOnF+uG1+Q=","actionRuleList":[{"uuid":"87eaf04e-e4d5-4a35-830b-47fd3a61965a","name":"Tagging-VM","isEnabled":true,"validated":true,"triggerList":[{"uuid":"68934a7d-5c46-4465-85a1-b68e38471eb1","triggerType":{"type":"trigger_type","uuid":"","name":"event_trigger"},"displayName":"Event","inputParameterList":[{"name":"category_filter_list","value":"[]"},{"name":"type","value":"VmPowerOnAudit"},{"name":"operation_type","value":"4"},{"name":"source_entity_info_list","value":"[]"}]}],"actionList":[{"uuid":"de35703b-2906-4cc5-ace1-5924f8c9086f","actionType":{"type":"action_type","uuid":"","name":"branch_action"},"displayName":"Branch","inputParameterList":[{"name":"condition","value":"["if","else"]"},{"name":"branch","value":"["2a863ffa-464a-4729-8c26-b5c5a3916bb5","d1697f02-6d15-4cbc-9e5d-60606eab39da"]"},{"name":"values","value":"["{{trigger[0].source_entity_info.name}}","[pP][aA][rR][sS][vV]"]"},{"name":"conditional_expression","value":"["{0}=regexp={1}"]"}],"maxRetries":2,"description":"@|","childActionUuids":["2a863ffa-464a-4729-8c26-b5c5a3916bb5","d1697f02-6d15-4cbc-9e5d-60606eab39da"]},{"uuid":"2a863ffa-464a-4729-8c26-b5c5a3916bb5","actionType":{"type":"action_type","uuid":"","name":"add_category_action"},"displayName":"Add to Category","inputParameterList":[{"name":"entity_type","value":"vm"},{"name":"category_entity_info","value":"[]"},{"name":"target_vm","value":"{{trigger[0].source_entity_info}}"}],"maxRetries":2,"description":"Environnement:Production"},{"uuid":"d1697f02-6d15-4cbc-9e5d-60606eab39da","actionType":{"type":"action_type","uuid":"","name":"wait_for_duration"},"displayName":"Wait for Some Time","inputParameterList":[{"name":"wait_duration","value":"0"},{"name":"stop_after_time","value":"true"},{"name":"post_check_trigger_validity","value":"false"},{"name":"block_resume","value":"false"}],"maxRetries":2,"postCheckTriggerValidity":false}],"isPrepackaged":false,"checkTriggerValidity":true,"triggerFilterableInputParamName":"type","triggerFilterableInputParamValue":"VmPowerOnAudit","ruleType":"kXPlay"}]}
Hi, I'm new to Nutanix Playbooks,
We took trial version of NCM. I'm Trying to create a playbook that will add VMs in categories.
I tried to rely on the Githubs one but I didn't find something similar. both playbooks "autocategorize_new_vms" and "autocategorize_vms_by_os" have the same trigger event : Vms created
I'm looking for something that will run immediatly and add VMs in categories regardless of the power state.
I'm not able to add pkb files so here is the content of it :
{"pcVersion":"7.3","pcUuid":"856361a1-c11e-48c7-91c5-5fce7fb45103","hashValue":"rUlxGfGYe3x8ieHgdUj0CdJhv9xzRj/GPVOnF+uG1+Q=","actionRuleList":[{"uuid":"87eaf04e-e4d5-4a35-830b-47fd3a61965a","name":"Tagging-VM","isEnabled":true,"validated":true,"triggerList":[{"uuid":"68934a7d-5c46-4465-85a1-b68e38471eb1","triggerType":{"type":"trigger_type","uuid":"","name":"event_trigger"},"displayName":"Event","inputParameterList":[{"name":"category_filter_list","value":"[]"},{"name":"type","value":"VmPowerOnAudit"},{"name":"operation_type","value":"4"},{"name":"source_entity_info_list","value":"[]"}]}],"actionList":[{"uuid":"de35703b-2906-4cc5-ace1-5924f8c9086f","actionType":{"type":"action_type","uuid":"","name":"branch_action"},"displayName":"Branch","inputParameterList":[{"name":"condition","value":"["if","else"]"},{"name":"branch","value":"["2a863ffa-464a-4729-8c26-b5c5a3916bb5","d1697f02-6d15-4cbc-9e5d-60606eab39da"]"},{"name":"values","value":"["{{trigger[0].source_entity_info.name}}","[pP][aA][rR][sS][vV]"]"},{"name":"conditional_expression","value":"["{0}=regexp={1}"]"}],"maxRetries":2,"description":"@|","childActionUuids":["2a863ffa-464a-4729-8c26-b5c5a3916bb5","d1697f02-6d15-4cbc-9e5d-60606eab39da"]},{"uuid":"2a863ffa-464a-4729-8c26-b5c5a3916bb5","actionType":{"type":"action_type","uuid":"","name":"add_category_action"},"displayName":"Add to Category","inputParameterList":[{"name":"entity_type","value":"vm"},{"name":"category_entity_info","value":"[]"},{"name":"target_vm","value":"{{trigger[0].source_entity_info}}"}],"maxRetries":2,"description":"Environnement:Production"},{"uuid":"d1697f02-6d15-4cbc-9e5d-60606eab39da","actionType":{"type":"action_type","uuid":"","name":"wait_for_duration"},"displayName":"Wait for Some Time","inputParameterList":[{"name":"wait_duration","value":"0"},{"name":"stop_after_time","value":"true"},{"name":"post_check_trigger_validity","value":"false"},{"name":"block_resume","value":"false"}],"maxRetries":2,"postCheckTriggerValidity":false}],"isPrepackaged":false,"checkTriggerValidity":true,"triggerFilterableInputParamName":"type","triggerFilterableInputParamValue":"VmPowerOnAudit","ruleType":"kXPlay"}]}