Giter Site home page Giter Site logo

awslabs / amazon-aurora-postgres-monitoring Goto Github PK

View Code? Open in Web Editor NEW
35.0 35.0 7.0 324 KB

An advanced monitoring system for Amazon Aurora PostgreSQL that is completely serverless, based on AWS Lambda and Amazon CloudWatch

License: Apache License 2.0

Python 98.14% Shell 1.86%
aurora cloudwatch lambda monitoring monitoring-tool postgres postgresql postgresql-database serverless

amazon-aurora-postgres-monitoring's People

Contributors

amazon-auto avatar paulramsey avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

amazon-aurora-postgres-monitoring's Issues

Does not support https proxy

Our VPC requires the use of our managed HTTPS proxy for egress. I tried every possible way to set an environment variable to get the lambda to use the proxy. Nothing worked. I had to modify the code like this:

    https_proxy = os.environ.get('HTTPS_PROXY')
    proxy_definitions = {
        'https': https_proxy,
    }

    config = Config(region_name=aws_region, connect_timeout=boto_timeout, retries={'max_attempts': boto_retries}, proxies_config={'proxy_use_forwarding_for_https': True}, proxies=proxy_definitions)

The proxy_use_forwarding_for_https is the critical bit of config. It might work without the proxies and be able to get the proxy directly from the environment variable, but I didn't test that combination. I just know that nothing worked until I set proxy_use_forwarding_for_https to True.

I'm sure this could all be made more generic so that you could control the proxy config without code changes, but I just wanted to share what worked for me.

password must be base64-encoded before encryption

The example CLI command to encrypt the password is not correct. You need to base64-encode the password before passing it to aws kms encrypt.

If you're lucky, and your password string is not base64, you'll get an error when you call aws kms encrypt, and this will all be obvious.

But it's possible that your password actually is a valid base64 string (e.g. "test"), in which case aws kms encrypt will accept it, decode it into a binary string and encrypt that. When the lambda decrypts it, it will get the binary string, not the password string you want.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.