djloude / cloudwatch_exporter_metrics_config_builder Goto Github PK
View Code? Open in Web Editor NEWCI/CD pipeline that generates aws cloudwatch metrics and dimensions then builds the cloudwatch.yml file.
CI/CD pipeline that generates aws cloudwatch metrics and dimensions then builds the cloudwatch.yml file.
Ansible playbook returns error when ran. See example full error message:
failed: [localhost] (item=/cloudwatch_exporter_metrics_config_builder/cloudwatch_config_builder/files/cloudwatch_metrics/auto_scaling.json) => {
"ansible_facts": {},
"ansible_included_var_files": [],
"ansible_loop_var": "item",
"changed": false,
"item": "cloudwatch_exporter_metrics_config_builder/cloudwatch_config_builder/files/cloudwatch_metrics/transit_gateway.json",
"message": "cloudwatch_exporter_metrics_config_builder/cloudwatch_config_builder/files/cloudwatch_metrics/transit_gateway.json must be stored as a dictionary/hash"
}
Here's how the cloudwatch_config_builder/files/cloudwatch_metrics/transit_gateway.json
generated from the pipeline.sh
script looks like:
cat transit_gateway.json
None
METRICS BytesDropCountBlackhole AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-09fcdd27877bd8abd
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS PacketsOut AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-06569e5eae5c15d3e
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS BytesIn AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-09fcdd27877bd8abd
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS PacketDropCountBlackhole AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-09fcdd27877bd8abd
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS PacketsIn AWS/TransitGateway
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS BytesOut AWS/TransitGateway
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS BytesDropCountBlackhole AWS/TransitGateway
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS PacketDropCountNoRoute AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-06569e5eae5c15d3e
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS BytesOut AWS/TransitGateway
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS BytesIn AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-06569e5eae5c15d3e
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS PacketDropCountNoRoute AWS/TransitGateway
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS PacketsOut AWS/TransitGateway
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS BytesOut AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-06569e5eae5c15d3e
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS PacketsIn AWS/TransitGateway
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS BytesDropCountBlackhole AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-06569e5eae5c15d3e
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS BytesOut AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-09fcdd27877bd8abd
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS BytesDropCountNoRoute AWS/TransitGateway
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS PacketsIn AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-06569e5eae5c15d3e
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS BytesDropCountBlackhole AWS/TransitGateway
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS PacketDropCountBlackhole AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-06569e5eae5c15d3e
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS BytesIn AWS/TransitGateway
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS PacketsIn AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-09fcdd27877bd8abd
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS PacketsOut AWS/TransitGateway
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS PacketDropCountNoRoute AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-09fcdd27877bd8abd
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS PacketsOut AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-09fcdd27877bd8abd
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS BytesIn AWS/TransitGateway
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS PacketDropCountNoRoute AWS/TransitGateway
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS BytesDropCountNoRoute AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-06569e5eae5c15d3e
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS PacketDropCountBlackhole AWS/TransitGateway
DIMENSIONS TransitGateway tgw-07ad63cf278f3f4e7
METRICS BytesDropCountNoRoute AWS/TransitGateway
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS BytesDropCountNoRoute AWS/TransitGateway
DIMENSIONS TransitGatewayAttachment tgw-attach-09fcdd27877bd8abd
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
METRICS PacketDropCountBlackhole AWS/TransitGateway
DIMENSIONS TransitGateway tgw-0e0d912367b7a1c3a
I can confirm that running the aws cloudwatch list-metrics
command generates the same output. I suspect the problem is with the way the main.py
script is written because I tried manually changing one of the files to simply
cat transit_gateway.json
some_variable: value
, then the ansible playbook passes for that particular file.
Getting this error when running initially
Python 3.10.8
./pipeline.sh: line 2: cloudwatch_config_builder/files/cloudwatch_metrics/auto_scaling.json: No such file or directory
./pipeline.sh: line 3: cloudwatch_config_builder/files/cloudwatch_metrics/billing.json: No such file or directory
./pipeline.sh: line 4: cloudwatch_config_builder/files/cloudwatch_metrics/dynamo_db.json: No such file or directory
./pipeline.sh: line 5: cloudwatch_config_builder/files/cloudwatch_metrics/ebs.json: No such file or directory
./pipeline.sh: line 6: cloudwatch_config_builder/files/cloudwatch_metrics/ec2.json: No such file or directory
./pipeline.sh: line 7: cloudwatch_config_builder/files/cloudwatch_metrics/elasti_cache.json: No such file or directory
./pipeline.sh: line 8: cloudwatch_config_builder/files/cloudwatch_metrics/events.json: No such file or directory
./pipeline.sh: line 9: cloudwatch_config_builder/files/cloudwatch_metrics/lambda.json: No such file or directory
./pipeline.sh: line 10: cloudwatch_config_builder/files/cloudwatch_metrics/logs.json: No such file or directory
./pipeline.sh: line 11: cloudwatch_config_builder/files/cloudwatch_metrics/network_elb.json: No such file or directory
./pipeline.sh: line 12: cloudwatch_config_builder/files/cloudwatch_metrics/rds.json: No such file or directory
./pipeline.sh: line 13: cloudwatch_config_builder/files/cloudwatch_metrics/s3.json: No such file or directory
./pipeline.sh: line 14: cloudwatch_config_builder/files/cloudwatch_metrics/transit_gateway.json: No such file or directory
./pipeline.sh: line 15: cloudwatch_config_builder/files/cloudwatch_metrics/trusted_advisor.json: No such file or directory
./pipeline.sh: line 16: cloudwatch_config_builder/files/cloudwatch_metrics/usage.json: No such file or directory
It is fixed by adding cloudwatch_config_builder/files/cloudwatch_metrics/ folder
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.