# Azure Deployment

## Summary of Steps <a href="#summary-of-steps" id="summary-of-steps"></a>

### Prerequisites <a href="#prerequisites" id="prerequisites"></a>

1. Set up an SMTP server. When a Gov is deploying care, the Gov should provide email gateway credentials along with domains.
2. Set up a Sentry project for error management.

### CARE Infrastructure Deployment <a href="#care-infrastructure-deployment" id="care-infrastructure-deployment"></a>

1. Create a Virtual Network.
2. Create a PostgreSQL Server. Create database and add PostGIS extension.
3. Create a S3 compatable storage (Since Azure Storage account does not support S3 API) and get credentials for the storage.
4. Create a private AKS cluster.
5. Create a VM instance as a jump server.
6. Create a VM instance as a bastion host, install VPN, and whitelist its IP in the jumpservers network security group.
7. Configure a self-hosted agent (linux) in the jumpserver for CI/CD pipelines.
8. Update configurations for each deployment in their corresponding YAML files.
9. Create the deployments using the CI/CD pipelines from Github.

### Metabase Deployment <a href="#metabase-deployment" id="metabase-deployment"></a>

1. Create a VM instance in the same VNET as CARE.
2. Create a PostgreSQL Server. Create a database for Metabase in it.
3. Create a read-replica of CARE Database for Metabase to read data from.
4. Follow the installation steps from the official documentation.
5. Create a load balancer and expose the service.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://deploydocs.coronasafe.network/cloud-deployment-overview/azure.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
