Requires 2 shortcuts. One parses the JSON at JSON Page shortcuts-simple-remote-commands to generate commands. The other provides selection menus and then runs the selected command on the selected host.
Future:
- use a github repo to host json.
- Display name for selection rather than command.
- Restore option to run a shortcut for more complex commands
- Examination of JSON Fetching Shortcut
Install both shortcuts:
- Fetch JSON File (can be replaced with a shortcut that returns a List of Dictionaries (see JSON).
Fetch https://dougbeal.com/shortcuts-simple-remote-commands/ v1 - Select host and command, then run command on host via SSH.
macOS Remote Automation v1
Then
- Open macOS Remote Automation v1 and modify
LIST
to have your hostnames and theDICTIONARY
to have your username. - Find
SHORTCUTS Run
and select Fetch https://dougbeal.com/shortcuts-simple-remote-commands/ v1
See Remote control your Mac with your iPhone and SSH Key Shortcuts to set up your Mac for remote access.
#NovBaD #NaBloPoMo #challenge4of30 #challenge #automation #shortcuts #iOS #macOS #SSH
Douglas Beal mentioned this article on dougbeal.com.
Matthew Cassinelli liked this article on twitter.com.