Global SSH Commands
Global SSH commands let you define a deployment command once at the account level and reuse it across any project in your account. Instead of recreating the same "restart services" or "clear cache" command in every project, you manage it in one place and link it wherever you need it.
You can create and manage global SSH commands from Settings > Global SSH Commands. Each command defines what to run, whether the deployment should stop if it fails, and a timeout. When and where each command runs is decided separately for every project that uses it.
Adding a command to a project
Open a project's SSH Commands page and choose Add Global SSH Command. Added commands appear alongside the project's own commands. For each one you choose, within that project, whether it runs before or after your files change, on which servers or server groups, and how often (every deployment, only the first, or after the first) — while the command itself stays managed at the account level.
Within a phase, added commands and the project's own commands share one list that you can drag to reorder, so you decide exactly where each one runs.
Editing a command
Because a global SSH command is shared, editing it from Settings > Global SSH Commands updates it everywhere it is linked. To stop a command from running on a project, unlink it from that project's SSH Commands page — this leaves the global command and its other links untouched.
Tip: You can also manage global SSH commands using the DeployHQ API. You can explore and test these endpoints interactively using our OpenAPI documentation.