cfn-guardian 0.11.11 → 0.11.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ea93d9929e6a71637cf54a77b0b50fbfe2fde9aea4ce619e7eaceb2558d86aea
|
4
|
+
data.tar.gz: 0aec62a664ab2fe33f41cc923a050a96c020322b9b6fa983bba423519068292c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c2e5e97db34ced3180e8754af50b68cda8a5e1e81fac6e0f0d81427d6673741ee4d05df5184c4b7a8c4f4b4978a5c9fbc1adf7c3a75b101c7537e5774cdd5d45
|
7
|
+
data.tar.gz: efcc2889fb227c9ed3fbdc08e7c8ad310b750702e7f0b8cf89859f61d23c3c310ea0f1e4e0ac7e8f46fcaab6489d0a4d606d4a8571bb27e06bbdd0cf03b1405b
|
data/docs/alarm_templates.md
CHANGED
@@ -29,6 +29,7 @@ cfn-guardian show-alarms --defaults --group ApplicationTargetGroup --alarm Targe
|
|
29
29
|
| ActionsEnabled | true |
|
30
30
|
| AlarmAction | Critical |
|
31
31
|
| TreatMissingData | notBreaching |
|
32
|
+
| OkActionDisabled | false |
|
32
33
|
+-------------------------+----------------------------------+
|
33
34
|
```
|
34
35
|
|
@@ -113,6 +114,19 @@ Templates:
|
|
113
114
|
CPUUtilizationHigh: false
|
114
115
|
```
|
115
116
|
|
117
|
+
## Disabling The OK Action On An Alarm
|
118
|
+
|
119
|
+
You can disable the OK action on an alarm by setting the OkActionDisabled flag to `true`. You might want to do this if you just want to receive alarm notifications rather than treat it as stateful.
|
120
|
+
|
121
|
+
```yaml
|
122
|
+
Templates:
|
123
|
+
# define the resource group
|
124
|
+
Ec2Instance:
|
125
|
+
# define the Alarm and set the OkActionDisabled value to true
|
126
|
+
CPUUtilizationHigh:
|
127
|
+
OkActionDisabled: true
|
128
|
+
```
|
129
|
+
|
116
130
|
## M Out Of N Metric Data Points
|
117
131
|
|
118
132
|
This can be good to alert on groups of spikes with in a certain time frame without getting alerts for individual spikes.
|
@@ -32,6 +32,7 @@ module CfnGuardian
|
|
32
32
|
['EvaluateLowSampleCountPercentile', alarm.evaluate_low_sample_count_percentile],
|
33
33
|
['Unit', alarm.unit],
|
34
34
|
['AlarmAction', alarm.alarm_action],
|
35
|
+
['OkActionDisabled', alarm.ok_action_disabled],
|
35
36
|
['TreatMissingData', alarm.treat_missing_data]
|
36
37
|
]
|
37
38
|
|
@@ -72,7 +73,8 @@ module CfnGuardian
|
|
72
73
|
['EvaluateLowSampleCountPercentile', alarm.evaluate_low_sample_count_percentile, metric_alarm.evaluate_low_sample_count_percentile],
|
73
74
|
['Unit', alarm.unit, metric_alarm.unit],
|
74
75
|
['TreatMissingData', alarm.treat_missing_data, metric_alarm.treat_missing_data],
|
75
|
-
['AlarmAction', alarm.alarm_action, alarm.alarm_action]
|
76
|
+
['AlarmAction', alarm.alarm_action, alarm.alarm_action],
|
77
|
+
['OkActionDisabled', alarm.ok_action_disabled]
|
76
78
|
]
|
77
79
|
|
78
80
|
rows.select! {|row| !row[1].nil?}.each {|row| colour_compare_row(row)}
|
@@ -19,6 +19,7 @@ module CfnGuardian
|
|
19
19
|
:comparison_operator,
|
20
20
|
:statistic,
|
21
21
|
:actions_enabled,
|
22
|
+
:ok_action_disabled,
|
22
23
|
:enabled,
|
23
24
|
:resource_id,
|
24
25
|
:resource_name,
|
@@ -45,6 +46,7 @@ module CfnGuardian
|
|
45
46
|
@comparison_operator = 'GreaterThanThreshold'
|
46
47
|
@statistic = 'Maximum'
|
47
48
|
@actions_enabled = true
|
49
|
+
@ok_action_disabled = false
|
48
50
|
@datapoints_to_alarm = nil
|
49
51
|
@extended_statistic = nil
|
50
52
|
@evaluate_low_sample_count_percentile = nil
|
@@ -149,9 +149,9 @@ module CfnGuardian
|
|
149
149
|
@group = 'Sql'
|
150
150
|
@name = 'SqlCheck'
|
151
151
|
@package = 'aws-lambda-sql-check'
|
152
|
-
@handler = '
|
153
|
-
@version = '
|
154
|
-
@runtime = '
|
152
|
+
@handler = 'bootstrap'
|
153
|
+
@version = '21fc960d68550581bfe8fa8fef2014f5de832514'
|
154
|
+
@runtime = 'provided.al2'
|
155
155
|
@subnets = resource['Subnets']
|
156
156
|
@vpc = resource['VpcId']
|
157
157
|
@environment = resource['Environment']
|
@@ -48,7 +48,7 @@ module CfnGuardian
|
|
48
48
|
MetricName alarm.metric_name
|
49
49
|
Namespace alarm.namespace
|
50
50
|
AlarmActions actions
|
51
|
-
OKActions actions
|
51
|
+
OKActions actions unless alarm.ok_action_disabled
|
52
52
|
TreatMissingData alarm.treat_missing_data unless alarm.treat_missing_data.nil?
|
53
53
|
DatapointsToAlarm alarm.datapoints_to_alarm unless alarm.datapoints_to_alarm.nil?
|
54
54
|
ExtendedStatistic alarm.extended_statistic unless alarm.extended_statistic.nil?
|
data/lib/cfnguardian/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cfn-guardian
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.11.
|
4
|
+
version: 0.11.13
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Guslington
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2025-03-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|
@@ -390,7 +390,7 @@ metadata:
|
|
390
390
|
homepage_uri: https://github.com/base2Services/cfn-guardian
|
391
391
|
source_code_uri: https://github.com/base2Services/cfn-guardian
|
392
392
|
changelog_uri: https://github.com/base2Services/cfn-guardian
|
393
|
-
post_install_message:
|
393
|
+
post_install_message:
|
394
394
|
rdoc_options: []
|
395
395
|
require_paths:
|
396
396
|
- lib
|
@@ -406,7 +406,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
406
406
|
version: '0'
|
407
407
|
requirements: []
|
408
408
|
rubygems_version: 3.1.6
|
409
|
-
signing_key:
|
409
|
+
signing_key:
|
410
410
|
specification_version: 4
|
411
411
|
summary: Manages AWS cloudwatch alarms with default templates using cloudformation
|
412
412
|
test_files: []
|