{"id":22712119,"url":"https://github.com/buildit/pe-community-aws-cloudwatch","last_synced_at":"2025-03-29T22:21:34.567Z","repository":{"id":78235751,"uuid":"104522370","full_name":"buildit/pe-community-aws-cloudwatch","owner":"buildit","description":"Demonstration project for Platform Engineer Community presentation on AWS CloudWatch.","archived":false,"fork":false,"pushed_at":"2017-09-25T14:18:01.000Z","size":21,"stargazers_count":2,"open_issues_count":0,"forks_count":2,"subscribers_count":16,"default_branch":"master","last_synced_at":"2025-02-04T23:31:19.900Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/buildit.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-09-22T22:02:20.000Z","updated_at":"2019-04-08T09:46:15.000Z","dependencies_parsed_at":"2023-03-18T05:15:40.842Z","dependency_job_id":null,"html_url":"https://github.com/buildit/pe-community-aws-cloudwatch","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buildit%2Fpe-community-aws-cloudwatch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buildit%2Fpe-community-aws-cloudwatch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buildit%2Fpe-community-aws-cloudwatch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buildit%2Fpe-community-aws-cloudwatch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/buildit","download_url":"https://codeload.github.com/buildit/pe-community-aws-cloudwatch/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246250086,"owners_count":20747293,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-10T13:09:28.869Z","updated_at":"2025-03-29T22:21:34.561Z","avatar_url":"https://github.com/buildit.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![GitPitch](https://gitpitch.com/assets/badge.svg)](https://gitpitch.com/buildit/pe-community-aws-cloudwatch)\n\nCloudWatch Example Project\n==========================\nThis project is a simple/stupid example of setting up and using CloudWatch Logging, Metrics, and Alerts.  \nNormally, you'd do this in an EC2 instance, but I thought it would be useful/convenient/interesting to automate and\ndemonstrate using Vagrant.\n\nPrerequisites\n-------------\n\n- _Vagrant_\n\n  The latest copy is the best bet.\n\n- _AWS Credentials_\n\n  The VM gets configured with AWS CLI credentials you provide on the command line.  The credentials \n  specified require appropriate CloudWatch permissions.\n\nGetting Started\n---------------\nOnce you've cloned this repo, just do a `vagrant up`.\n\nOK, it's not necessarily quite that simple.  You'll want your AWS credentials to be present in your\nenvironment.  If you use a credentials file, you'll want to do `vagrant up`, but provide the \nvariables along the way:\n\n```AWS_REGION=\"\u003cregion you like\u003e\" NOTIFICATION_EMAIL=\"your.email@yourdomain.com\" DISCRIMINATOR=\"\u003csome hopefully unique name\u003e\" AWS_ACCESS_KEY_ID=\"\u003cyour key\u003e\" AWS_SECRET_ACCESS_KEY=\"\u003cyour secret key\u003e\" vagrant up```\n\n(note:  I've only tested in `us-east-1`, so it might be best to like it most  :-\\ )\n\nThe `DISCRIMINATOR` variable is used to separate your stuff by some useful name.  Your first initial and last name is a good way to go.\n\nOnce started, Vagrant does the rest.  Note that you will receive an SNS subscription confirmation email at the address you provided\nonce the VM is configured.  _You must confirm the subscription in order to receive alert emails._\n\nExperimenting\n-------------\nOnce the VM is started, use `vagrant ssh` to get into the instance and look around.  While you're in there,\nbe sure to do some stuff as as root, such as add new users (`sudo useradd -m \u003csomeusername\u003e`) or just become root \nwith `sudo su`.  All these activities are monitored by the CloudWatch Log Metrics put in place by the provisioning \nscript, so run a few cases through.\n\nTo see the effects of your activities as well as other activities performed by the included scripts, log into\nthe AWS console and navigate to CloudWatch.  Note the sub-sections of CloudWatch in the left-hand menu.\n\n - Check CloudWatch Logs:  type your discriminator into the filter box and hit enter.  You should see a few Log\n   Groups reflected.  Click in to browse the logs.\n - Check out Metrics:  in the Metrics console click on PeChatMetrics.  Investigate the metrics that have been\n   created by the script.  Some metrics are separated by dimension (based on `DISCRIMINATOR`) and some are not.  \n   If you experimented as suggested above, the graphs should show some interesting activity (your own, and that \n   of others that are running the code). \n - Experiment with Dashboards:  try creating a Dashboard (Actions in the Graph Options tab of Metrics).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuildit%2Fpe-community-aws-cloudwatch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbuildit%2Fpe-community-aws-cloudwatch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuildit%2Fpe-community-aws-cloudwatch/lists"}