> For the complete documentation index, see [llms.txt](https://docs.scepman.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.scepman.com/pt/configuracao-do-azure/health-check.md).

# Verificação de estado

Você pode monitorar a integridade do SCEPman usando

* o [o recurso Health Check dos Serviços de Aplicativo do Azure](#health-check-in-azure-app-services) (recomendado) ou
* uma [ferramenta de monitoramento de terceiros](/pt/configuracao-do-azure/health-check/using-3rd-party-monitoring.md).

## Health Check nos Serviços de Aplicativo do Azure

Você pode configurar o recurso Health Check e o alerta correspondente para o App Service para receber uma notificação direta caso sua instância do SCEPman deixe de responder.

### Configurar Health Check

{% hint style="info" %}
Novas instalações do SCEPman adicionam o Health Check automaticamente durante a instalação, a partir do SCEPman 2.11. Se você instalou o SCEPman antes disso, pode adicionar o Health Check manualmente usando as instruções abaixo. Se você instalou o SCEPman quando ele já estava na versão 2.11 ou posterior, pule para a próxima seção [Configurar Alertas](#configure-alerting). **Mesmo com instalações do SCEPman 2.11, o Alerting não é adicionado automaticamente e ainda precisa ser configurado!**
{% endhint %}

1. Navegue até o seu **App Service** e, no lado esquerdo, role até **Health check**
2. Agora você pode **Ativar** o Health check, como caminho de sondagem **caminho** insira o seguinte: **/probe**
3. Agora você pode clicar em **Salvar**, mas tenha em mente que **isso reiniciará o seu App Service**

![Ativar Health check](https://3802289327-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LoGejQeUQcw7lqnQ3WX%2Fuploads%2Fgit-blob-3c837746f832366bfd5abc27e41eba5ebe0f2cbe%2F2022-12-27%2013_04_05.png?alt=media)

### Configurar Alertas

Para receber um alerta do nosso Health check, precisamos configurar regras de alerta no nosso App Service.

1. Navegue até o seu **App Service** e, no lado esquerdo, role até **Alertas**
2. Clique em **Criar regra de alerta**
3. Na sua nova regra de alerta, você será automaticamente redirecionado para **Adicionar condição**
4. Selecione uma lógica de sinal. Procure por **Status do Health check**

![Criar regra de alerta](https://3802289327-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LoGejQeUQcw7lqnQ3WX%2Fuploads%2Fgit-blob-76f2206998eb07b7e055761bf29c5daf79fcc287%2F2022-12-27%2012_13_22.png?alt=media)

5. Configure o alerta conforme especificado abaixo:

| **Limite**                   | Estático   |
| ---------------------------- | ---------- |
| **Tipo de agregação**        | Média      |
| **Operador**                 | Menor que  |
| **Unidade**                  | Contagem   |
| **Valor do limite**          | 70         |
| **Verificar a cada**         | 5 minutos  |
| **Período de retrospectiva** | 15 minutos |

<figure><img src="https://3802289327-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LoGejQeUQcw7lqnQ3WX%2Fuploads%2FUQoISWcPXg3UxxSwjuWK%2Fimage.png?alt=media&amp;token=0ba717a9-c5c7-46d4-88d9-77b345c888b1" alt=""><figcaption><p>Condição da regra de alerta</p></figcaption></figure>

6. Clique em **Próximo: Ações**
7. Selecionar **Criar grupo de ação**

{% hint style="info" %}
Se você já tiver grupos de ação existentes, escolha **Selecionar grupos de ação**, selecione um grupo de ação e avance para a etapa 14.
{% endhint %}

8. Defina um **Nome do grupo de ação** e **Nome de exibição**

![Criar grupo de ação](https://3802289327-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LoGejQeUQcw7lqnQ3WX%2Fuploads%2Fgit-blob-90be8a37b636d9eee8dc7d1d3a55a909ea3777c3%2F2022-12-27%2012_29_38.png?alt=media)

9. Ao lado de **Notificações** e adicione **Tipo de notificação**
10. Na janela, marque a **Email** caixa de seleção e insira o endereço de e-mail no qual deseja receber notificações
11. Em seguida, clique em **OK**
12. Insira um **Nome** para o tipo de notificação

![Defina as notificações para o grupo de ação](https://3802289327-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LoGejQeUQcw7lqnQ3WX%2Fuploads%2Fgit-blob-2aad32a044ba452b06fd95efb534f960269f509a%2Fscreen-shot-2021-01-19-at-11.11.40.png?alt=media)

13. Depois disso, você pode clicar em **Revisar + criar** e então em **Criar.** Você será redirecionado de volta para **Ações** na criação da regra de alerta
14. Ao lado de D**etalhes**, configure o seguinte
    * **Grupo de recursos**
    * **Gravidade**
    * **Nome da regra de alerta**
    * Ativar: **Ativar após a criação**
    * Ativar: **Resolver alertas automaticamente**

<figure><img src="https://3802289327-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LoGejQeUQcw7lqnQ3WX%2Fuploads%2FV30enHQO0XCTeiJbw7SJ%2F2023-10-23%2013_51_20-Create%20an%20alert%20rule.png?alt=media&amp;token=51b6d634-9664-4fd8-839d-337060f1ce5e" alt=""><figcaption><p>Detalhes do alerta</p></figcaption></figure>

15. Clique em **Revisar + Criar,** depois **Criar**

<figure><img src="https://3802289327-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LoGejQeUQcw7lqnQ3WX%2Fuploads%2FMlLdeqIoA2IqarutyTqZ%2F2023-10-23%2013_55_02-Create%20an%20alert%20rule.png?alt=media&amp;token=dc8e6678-85f6-439a-9228-bbbe8b5b5f22" alt=""><figcaption></figcaption></figure>

16. Visualize seus **Regras de alerta** como mostrado

![Ver regras de alerta existentes](https://3802289327-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LoGejQeUQcw7lqnQ3WX%2Fuploads%2Fgit-blob-334e32bdfdaa0de830345007109837ecf0be9814%2F2022-12-27%2012_46_42.png?alt=media)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.scepman.com/pt/configuracao-do-azure/health-check.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
