Automation and Scheduled Deployments
The DeployHQ CLI lets you configure automated deployment triggers, scheduled deployments, notification integrations, and network agents.
Automatic Deployments
Automatic deployments trigger a deployment whenever changes are pushed to your repository.
Listing Auto-Deploy Configuration
dhq auto-deploys list -p my-app
Enabling Auto-Deploy for a Server
dhq auto-deploys enable -p my-app --server production
Disabling Auto-Deploy
dhq auto-deploys enable -p my-app --server production --disable
Scheduled Deployments
Scheduled deployments run on a recurring schedule (e.g., deploy to staging every night).
Listing Scheduled Deployments
dhq scheduled-deploys list -p my-app
Viewing a Scheduled Deployment
dhq scheduled-deploys show <id> -p my-app
Creating a Scheduled Deployment
dhq scheduled-deploys create -p my-app \
--server staging \
--frequency daily
Deleting a Scheduled Deployment
dhq scheduled-deploys delete <id> -p my-app
Integrations
Integrations send notifications about deployments to external services (e.g., Slack, email, webhooks).
Listing Integrations
dhq integrations list -p my-app
Viewing an Integration
dhq integrations show <id> -p my-app
Creating an Integration
dhq integrations create -p my-app \
--type slack \
--settings '{"webhook_url":"https://hooks.slack.com/services/..."}'
Updating an Integration
dhq integrations update <id> -p my-app \
--settings '{"webhook_url":"https://hooks.slack.com/services/new-url"}'
Deleting an Integration
dhq integrations delete <id> -p my-app
Network Agents
Network agents allow DeployHQ to deploy to servers behind firewalls. The agent runs on a server inside your network and creates an outbound connection to DeployHQ.
Listing Agents
dhq agents list
Creating an Agent
dhq agents create --name "Office Network" --zone eu
Updating an Agent
dhq agents update <id> --name "New Office Network"
Revoking Agent Credentials
If an agent's credentials are compromised, revoke them:
dhq agents revoke <id>
After revoking, you will need to reconfigure the agent with new credentials.
Deleting an Agent
dhq agents delete <id>