If you SCXE or a third party editor, you should have access to the nuking AI Scripts.
Build the nuke with "B/W Terran 2-A Fill Silos With Nuke (Type 2)" (type 1 is specific to a certain BW campaign map and will create Ghosts at certain places relative to the location, it'll just screw you up). Then you launch it with "AI Nuke Here." I believe a Ghost has to be in range or in the location, it won't walk there. It's been at least two years since I did nuke related things with triggers, so bear with me. I would just create a Ghost in a location and have AI Nuke Here in that location. That Ghost should nuke on top of itself.
Depending on how you're using the nuke, it may be useful to know exactly how it works.
http://www.staredit.net/index.php?tutorial=146
There was a map that showed you how to provoke spell use from the AI. I believe Ensnare works if you have a cloaked unit attack the Queen, or a clump of 6 or 8 units. Again, this is old stuff so I don't remember it too clearly, experiment with it. I spent most of my time fiddling with Yomato shots. I'll look for the map. If I recall correctly, it'll never use Ensnare freely (just once or twice if you're lucky).