Skip to content

Commit 8995111

Browse files
committed
add section monitor
1 parent d79deef commit 8995111

File tree

5 files changed

+64
-1
lines changed

5 files changed

+64
-1
lines changed
455 KB
Loading
391 KB
Loading
547 KB
Loading
341 KB
Loading

src/content/docs/en/sdk/guides/aws-deployment.mdx

Lines changed: 64 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ import ToggleElement from "../../../../../components/ToggleElement.astro";
1414
import AWSCloudflareDNSWildcards from "./_images/aws-cloudflare-dns-wildcards.png";
1515
import AWSCloudflareDNS from "./_images/aws-cloudflare-dns.png";
1616
import AWSEBSDriver from "./_images/aws-ebs-driver.png";
17+
import CreateSlackApp from "./_images/CreateSlackApp.png"
18+
import AddNewWebhookToWorkspace from "./_images/AddNewWebhookToWorkspace.png"
19+
import CopyWebhookURL from "./_images/CopyWebhookURL.png"
20+
import GrafanaDashboard from "./_images/grafana.png"
1721

1822
This guide demonstrates how to deploy a Scroll SDK on Amazon Web Services (AWS) using Elastic Kubernetes Service (EKS) and other managed services.
1923

@@ -807,4 +811,63 @@ controller:
807811

808812
Some services do not support this without additional configurations (for example, `l2-sequencer` and `l2-bootnode`). We are working on additional info on how to properly run multiple services for load balancing between or for having redundant backups available.
809813

810-
{/* TODO: Fix this comment once we add this documentation */}
814+
{/* TODO: Fix this comment once we add this documentation */}
815+
816+
817+
### Monitoring
818+
You can monitor the cluster's running status through Grafana.
819+
Additionally, you can send alerts via email and Slack using Alertmanager.
820+
If you have configured a domain for Grafana in the previous steps, you can access it by opening http://grafana.yourdomain.xyz, where you will see two sets of dashboards.
821+
<ClickToZoom src={GrafanaDashboard} alt="Copy Webhook URL" />
822+
823+
#### send alert to slack
824+
1. **Create a Slack App**
825+
826+
Open [https://api.slack.com/apps](https://api.slack.com/apps) and click **`Create New App`** if you don't have one already. Select **`From scratch`**, enter a name, and select the workspace.
827+
828+
2. **Activate Incoming Webhooks**
829+
830+
Click the **`Incoming Webhooks`** label on the right side of the page, then turn on **`Activate Incoming Webhooks`**.
831+
<ClickToZoom src={CreateSlackApp} alt="Create Slack App" />
832+
833+
Click the **`Add New Webhook to Workspace`** button.
834+
<ClickToZoom src={AddNewWebhookToWorkspace} alt="Add New Webhook to Workspace" />
835+
836+
Select the channel you want to send alerts to, then copy the Webhook URL.
837+
<ClickToZoom src={CopyWebhookURL} alt="Copy Webhook URL" />
838+
839+
840+
3. **Edit the Config File**
841+
842+
Edit `./values/alert-manager.yaml` to replace it with your webhook URL and your Slack channel name.
843+
```
844+
kube-prometheus-stack:
845+
alertmanager:
846+
config:
847+
global:
848+
resolve_timeout: 5m
849+
slack_api_url: 'https://hooks.slack.com/services/xxxxxxxxxxx/xxxxxxxxxxx/xxxxxxxxxxxxxxxxxxxxxxxx' # your webhook url
850+
receivers:
851+
- name: 'slack-alerts'
852+
slack_configs:
853+
- channel: '#scroll-webhook' #your channel name
854+
send_resolved: true
855+
text: '{{ .CommonAnnotations.description }}'
856+
title: '{{ .CommonAnnotations.summary }}'
857+
route:
858+
group_by: ['alertname']
859+
receiver: 'slack-alerts'
860+
routes:
861+
- matchers: []
862+
receiver: 'slack-alerts'
863+
```
864+
This configuration file will send all alerts to your Slack channel. If you need more complex rules, refer to the [Prometheus Alerting Configuration Documentation](https://prometheus.io/docs/alerting/latest/configuration/).
865+
866+
4. **Update to alertmanager**
867+
868+
Use the following command to update Alertmanager:
869+
```
870+
helm upgrade -i scroll-monitor oci://ghcr.io/scroll-tech/scroll-sdk/helm/scroll-monitor -n $(NAMESPACE) \
871+
--version=0.0.4 \
872+
--values ./values/alert-manager.yaml
873+
```

0 commit comments

Comments
 (0)