MCPcopy Index your code
hub / github.com/aidansteele/rdsconn

github.com/aidansteele/rdsconn @v0.1.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.1.0 ↗ · + Follow
13 symbols 38 edges 3 files 0 documented · 0%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

rdsconn

On June 14th, 2023 AWS launched new connectivity options for EC2 Instance Connect. This functionality also works for non-EC2 resources in VPCs. You could run the official AWS CLI (>= v2.12.0) using the following command, but rdsconn aims to make the RDS experience easier.

aws ec2-instance-connect open-tunnel \
  --private-ip-address 10.1.2.150 \
  --instance-connect-endpoint-id eice-06d8b7ad48example \
  --remote-port 5432 \
  --local-port 5432

Installation

On macOS, brew install aidansteele/taps/rdsconn. On other platforms: see published binaries in the releases tab of the GitHub repo.

Usage

  1. Create an EC2 Instance Connect endpoint in your VPC. Ensure that your RDS DB instance's security group allows the EIC endpoint to connect to it.
  2. Have valid AWS credentials configured. E.g. either as environment variables, default credentials in your config file, or a profile with AWS_PROFILE=name env var set.
  3. Run rdsconn proxy. The CLI will prompt you to select an RDS DB instance from the list of DBs in your account. Hit enter to confirm selection.
  4. The message Proxy running. Now waiting to serve connections to localhost:5432... will appear. You can now run psql ... -h 127.0.0.1 (or mysql ...)

Future plans

  • Flesh out this README more
  • Detect incorrect configurations and provide helpful error messages to user. E.g. missing endpoints, security groups, routes, etc.
  • Add a client subcommand that uses RDS IAM authentication to launch and authenticate a child process psql CLI (using PGPASSWORD etc env vars)

Core symbols most depended-on inside this repo

promptForInstanceId
called by 1
proxy.go
listenerAndPort
called by 1
proxy.go
serve
called by 1
proxy.go
NewDialer
called by 1
ec2ic/dialer.go
DialContext
called by 1
ec2ic/dialer.go
runProxy
called by 0
proxy.go
main
called by 0
main.go
runList
called by 0
main.go

Shape

Function 7
Method 4
Struct 2

Languages

Go100%

Modules by API surface

ec2ic/dialer.go7 symbols
proxy.go4 symbols
main.go2 symbols

For agents

$ claude mcp add rdsconn \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page