Skip to main content
This guide walks you through deploying Unpage agents to a remote production environment, including containerization, PagerDuty webhook integration, and automated deployment via GitHub Actions.

Prerequisites

Before you begin, ensure you have basic familiarity with Unpage concepts and agent configuration

Containerizing Your Unpage Deployment

This guide covers how to deploy Unpage using Docker. Unpage is a python package and can be deployed using your favorite method for deploying python services!

Creating a Dockerfile

Create a Dockerfile in your desired profile directory (e.g., ~/.unpage/profiles/default) so it has access to your config.yaml and agent files:

Docker Compose Configuration

For local development and testing, create a docker-compose.yml:

Configuration Management

Create a production-ready config.yaml:

PagerDuty Integration

Setting Up PagerDuty Webhooks

1

Configure your production webhook URL

Determine your public webhook URL. This should be your deployed Unpage server with the /webhook path:
2

Create PagerDuty webhook

  1. In PagerDuty, navigate to IntegrationsGeneric Webhooks (v3)
  2. Click + New Webhook
  3. Configure the webhook:
    • Webhook URL: https://unpage.yourcompany.com/webhook
    • Event Subscriptions: Select events you want agents to handle:
      • incident.triggered - When new incidents are created
      • incident.acknowledged - When incidents are acknowledged
      • incident.escalated - When incidents escalate
      • incident.resolved - When incidents are resolved
    • Custom Headers (optional): Add authentication headers if needed
3

Test the webhook

Use PagerDuty’s webhook testing feature or create a test incident to verify your deployment receives webhooks correctly.

Agent Configuration for Production

Create production agents in your agents/ directory. Here’s an example production agent (agents/ssl-investigation.yaml):

Troubleshooting

Debug logs

Add the --debug flag to unpage agent serve to get detailed logs about what actions the server is taking.

MLflow tracing

See the Debugging with MLflow tracing page.