So, there's a couple of ways I can think of to do it.
One would be to use IMC, and go to VLAN Management -> Global VLAN.
Find your VLAN, and then find the list of devices that have that particular VLAN.
Then create a config task that makes the changes you need. Run that task against that list of devices you discovered earlier.
It is also possible to use IMC to only take actions if specific conditions are met. You can create a Configuration Template than runs actions, looks at the response, and can then change its next step. So in theory you could do something that checks for the existence of a specific VLAN, then only runs the jumbo frames commands if needed.
I've never quite figured out the syntax for it though...