Aurora PostgreSQL: Database Object creations using AWS CLI/SAM CLI/Cloud formation

0

We looking way to deploy the Database objects on the PostgreSQL Database without using the external tool like pgadmin4.

I know two commonly used method to deploy the database objects

  1. Connect to PostgreSQL cluster using third part tool and create the objects
  2. Lambda which execute the sql qurty on PostgreSQL Database

I'm wondering if there a way we can create objects via CLI or other way so we don't need to enable the Public Access for Database Cluster or Expose Port 5432 over the Internet.

1 回答
0

As you say, you can use a Lambda to connect to the DB and execute SQL. If it's a VPC Lambda then you don't need your DB to be public or expose a port over the Internet.

You can integrate the Lambda tightly with CloudFormation as a Custom Resource or Resource Type.

For Custom Resources implemented in Python Lambdas, crhelper makes it really easy.

专家
已回答 1 年前
  • Hi,

    Thanks for your response.

    I'm looking options other then lambda as we do have very large functions, tables etc. which will be very difficult to manage in the code file.

    AWS document suggest we do have such API on earlier Serverless 1 Instance Type but this only support older version of PostgreSQL.

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则