β Repository β π Compliance Engine β π CloudAware β π AWS β π CloudWatch β π‘οΈ Metric Alarm does not have any actions configuredπ’
π§ AWS CloudWatch Metric Alarm does not have any actions configured - prod.logic.yamlπ’
- Contextual name: π§ prod.logic.yamlπ’
- ID:
/ce/ca/aws/cloudwatch/metric-alarm-without-actions/prod.logic.yaml
- Tags:
- π’ Logic test success
- π’ Logic with extracts
- π’ Logic with test data
Usesβ
- π AWS CloudWatch Metric Alarm
- π AWS CloudWatch Metric Alarm - object.extracts.yaml
- π§ͺ test-data.json
Test Results π’β
Generated at: 2025-10-08T17:39:06.832548645Z Open
Result | Id | Condition Index | Condition Text | Runtime Error |
---|---|---|---|---|
π’ | test1 | βοΈ 99 | βοΈ isDisappeared(CA10__disappearanceTime__c) | βοΈ null |
π’ | test2 | βοΈ 199 | βοΈ not(extract('CA10__actionsEnabled__c')) | βοΈ null |
π’ | test3 | βοΈ 299 | βοΈ extract('CA10__alarmActions__c').isEmpty() && extract('CA10__insufficientDataActions__c').isEmpty() && extract('CA10__okActions__c').isEmpty() | βοΈ null |
π’ | test4 | βοΈ 300 | βοΈ otherwise | βοΈ null |
Generation Bundleβ
File | MD5 | |
---|---|---|
Open | /ce/ca/aws/cloudwatch/metric-alarm-without-actions/policy.yaml | 49FAF65A9CD918CB97C1E0D193BEEEC1 |
Open | /ce/ca/aws/cloudwatch/metric-alarm-without-actions/prod.logic.yaml | 5F5C5F84269BB31151422BB7B5444A6A |
Open | /ce/ca/aws/cloudwatch/metric-alarm-without-actions/test-data.json | 0C17AE7232E0AB7ED9391E156FFF6C47 |
Open | /types/CA10__CaAwsCloudWatchMetricAlarm__c/object.extracts.yaml | 1CA53D6631ECBBFFDE69117572DA2544 |
Available Commandsβ
repo-manager policies generate FULL /ce/ca/aws/cloudwatch/metric-alarm-without-actions/prod.logic.yaml
repo-manager policies generate DEBUG /ce/ca/aws/cloudwatch/metric-alarm-without-actions/prod.logic.yaml
repo-manager policies generate CAPTURE_TEST_DATA /ce/ca/aws/cloudwatch/metric-alarm-without-actions/prod.logic.yaml
repo-manager policies generate TESTS /ce/ca/aws/cloudwatch/metric-alarm-without-actions/prod.logic.yaml
# Execute tests
repo-manager policies test /ce/ca/aws/cloudwatch/metric-alarm-without-actions/prod.logic.yaml
Contentβ
---
inputType: "CA10__CaAwsCloudWatchMetricAlarm__c"
testData:
- file: "test-data.json"
importExtracts:
- file: "/types/CA10__CaAwsCloudWatchMetricAlarm__c/object.extracts.yaml"
conditions:
- status: "INCOMPLIANT"
currentStateMessage: "The CloudWatch alarm actions are disabled."
remediationMessage: "Consider enabling the alarm actions if the alarm is still required."
check:
NOT:
arg:
EXTRACT: "CA10__actionsEnabled__c" # actionsEnabled != true
- status: "INCOMPLIANT"
currentStateMessage: "The CloudWatch alarm does not have any actions configured\
\ for the ALARM, INSUFFICIENT_DATA, or OK states."
remediationMessage: "Configure at least one action for the ALARM, INSUFFICIENT_DATA,\
\ or OK state to ensure notifications or automated responses are triggered\
\ when the alarm changes state."
check:
AND:
args:
- IS_EMPTY:
arg:
EXTRACT: "CA10__alarmActions__c"
- IS_EMPTY:
arg:
EXTRACT: "CA10__insufficientDataActions__c"
- IS_EMPTY:
arg:
EXTRACT: "CA10__okActions__c"
otherwise:
status: "COMPLIANT"
currentStateMessage: "The CloudWatch alarm has at least one action configured."