- Ohai
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // v1.1.2 | |
| var https = require('https'); | |
| var zlib = require('zlib'); | |
| var crypto = require('crypto'); | |
| //Adding the sns module to send email | |
| var AWS = require('aws-sdk'); | |
| var endpoint = 'xxxxxxxxxxx.us-east-1.es.amazonaws.com'; | |
| exports.handler = function(input, context) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import json | |
| import boto3 | |
| import time | |
| # recieve the event | |
| # Contruct the log_stream | |
| # pull the log | |
| # send notification | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Process: | |
| - instance of a computer prg in execution | |
| - while running a code, the code is loaded from disk to memory | |
| Threads: | |
| - A process can run the program parrallely executing various instructions parallely | |
| - Each thread have their own stacks | |
| - But shares - Text, heap, etc | |
| A process in memory is divided as : |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| depends_on : | |
| - db # This makes the service to restart on the service that its depending on restarts. But not vice-versa | |
| restart: always # This tells the service to restart when a fault occurs | |
| ## some commands | |
| $ docker network ls | |
| $ docker network inspect <network_name> | |
| $ docker-compose exec <service_name> sh | |
| $ docker-compose scale <service_name>=3 # here 3 is the desired count |
- Obtain the root cert from: https://s3.amazonaws.com/rds-downloads/rds-combined-ca-bundle.pem . This cert will be used for connecting to the db instance when SSL is enforced
- Create a new parameter grp based on the DB engine version, as all the db instances are in default parameter grp [Default parameter grps cannot be modified]
- Change the rds.force_ssl to 1 from 0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Cloudformation Templates: | |
| - Improve security | |
| Cloudform the below: | |
| 1. CW Alerts | |
| 2. Elastic Search | |
| 3. | |
| RDS: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #List the consumer grps | |
| kafka-consumer-groups.bat --bootstrap-server x.x.x.x:9092 -list |