As the title mentioned, is regex automation possible in Hexnode?
Is regex automation possible in Hexnode?Solved
Replies (5)
I’m pretty sure I saw regex used in the macOS password policy while configuring it last week. I remember it clearly because I customized the password requirements using a regex pattern. You might want to check that section.
What exactly are you trying to automate? I don’t think regex directly runs automations by itself. But it can definitely help identify devices or extract specific values, which you can then use as conditions for automation rules.
Got it. That actually makes sense. I was thinking regex could directly start an automation rule, but using it to extract values first sounds more realistic.
Hi @amelia-smith,
Regex can support automation workflows in Hexnode, but it does not directly trigger automation actions. Instead, it is typically used to extract specific values from device data, which can then be used for Dynamic Groups or Custom Attributes that automation rules can target.
This usually follows a two-step approach.
Step 1: Extract data using Regex in a Custom Script
- Navigate to Manage > Select device(s) > Actions > Execute Custom Script.
- Upload a script that retrieves device information (such as hostname or system details).
- Enable Store output in custom attribute option.
- Select the custom attribute where the value should be saved.
- Enter a regex pattern to extract the relevant part of the script output.
Step 2: Create a Dynamic Group
- Navigate to Manage > Device Groups > New Dynamic Group.
- Enter the name and description (optional) for the dynamic group.
- Choose the custom attribute populated by the script as column under condition filters.
- Set the comparator to Is or Contains.
- Enter the value.
Devices matching this value will automatically be grouped and can then be targeted with policies, apps, or automation rules.
Please try this out, and let us know if there are any further questions.
Regards,
Sienna Carter
Hexnode UEM
Understood. That clears things up. Thanks for the detailed explanation!