Skip to main content
mimran
Staff
Staff
May 1, 2026

Technical Tip: Using Apple shortcuts to run SSH commands

  • May 1, 2026
  • 0 replies
  • 135 views

Description

This article explains how to set up SSH on a FortiGate device to be accessed and managed using Apple Shortcuts on macOS and iOS.

Scope

FortiGate.

Solution

Apple Shortcuts includes an SSH action that allows commands to be executed on a remote FortiGate device directly from an iPhone, iPad, or Mac. This capability simplifies automation of routine tasks such as restarting services, checking system status, or running scripts without opening an SSH terminal.


Shortcuts can be scheduled or triggered by specific events, and the output can be displayed on the device or shared through communication channels such as SMS, email, or other apps.


How to configure this feature on FortiGate and use in Apple Shortcuts, take the following steps:


Step 1:


Ensure that SSH is enabled under the Administrative Access of the interface to be accessed under Network -> Interfaces.


afb507e4.png


Step 2:


Identify the SSH port configured on FortiGate, under Settings. The default is 22.


44a81072.png


Step 3:


Create a new Apple Shortcut with the required task. The following is an example demonstrating how to retrieve system status by executing an SSH command through Apple Shortcuts.


95797425.png