Step 1: Update Alertmanager Service to NodePort
First, update the Alertmanager service so that it exposes a NodePort. In this example, the NodePort for Alertmanager is set to 32501. To modify the Alertmanager service, run:Step 2: Explore Existing Prometheus Alert Rules
Now, review the existing Prometheus alert rules to identify if there are any rules related to ArgoCD. Open the Prometheus UI and navigate to the rules tab. While you will see several rules like AlertmanagerFailedReload, AlertmanagerMembersInconsistent, and AlertmanagerFailedToSendAlerts, none are specifically configured for ArgoCD. For instance, an existing set of rules appears as follows:Step 3: Create a Custom ArgoCD Alert Rule
Add a custom alert that triggers when an ArgoCD application is out of sync. This alert uses the Prometheus metricargocd_app_info (assumed to be available) to check if the sync status is “OutOfSync.” If this condition persists for one minute, the alert is raised with a warning severity.
To add the new alert rule, edit the Prometheus rules in the monitoring namespace:
'prometheusrule' again:
Step 4: Validate the New Alert Rule
After updating the rules, check the Prometheus UI to confirm that the new ArgoCD alert appears alongside other Alertmanager rules. The rule forArgoApplicationOutOfSync should be visible similar to the examples below:
Step 5: Test the Alert by Simulating an Out-of-Sync Application
To trigger the new alert, simulate an ArgoCD application going out of sync. For example, modify the replica count in a deployment definition. The following is an example for a deployment named “solar-system”:ArgoApplicationOutOfSync alert should trigger within one minute.
Refresh the Alertmanager UI to view the generated alerts. You should see alerts for all out-of-sync ArgoCD applications. For example, the interface might display multiple alerts related to your ArgoCD applications.

This confirms that your ArgoCD Prometheus metrics are correctly triggering alerts in Alertmanager.