https://github.com/sst/torpedo
Connect to databases in private VPCs securely the easy way - no VPN required
https://github.com/sst/torpedo
Last synced: 6 months ago
JSON representation
Connect to databases in private VPCs securely the easy way - no VPN required
- Host: GitHub
- URL: https://github.com/sst/torpedo
- Owner: sst
- License: mit
- Created: 2023-10-13T02:49:28.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-02-16T15:43:06.000Z (over 1 year ago)
- Last Synced: 2024-11-01T17:37:11.716Z (11 months ago)
- Language: Go
- Homepage:
- Size: 28.3 KB
- Stars: 91
- Watchers: 4
- Forks: 3
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# torpedo
Connect to databases in private VPCs the easy way - no VPN required
## How it works
On first run, `torpedo` will create an ECS cluster (this does not cost anything). From there, any time you want to connect to a database `torpedo` will generate random SSH keys, spin up a temporary container that has access to your database, and forward a local port through it. Then you can connect to the database on `localhost` as though it were running locally. The container will be destroyed once you're done with your session.
## Usage
Make sure you have a default AWS profile set or manually set one with `AWS_PROFILE=xxx torpedo`
```shell
$ torpedo
🚀 torpedo is readyconnect to port 5432 on localhost
it's forwarded to main-1.cz73excokyft.us-east-2.rds.amazonaws.com:5432press ctrl+c to exit
```### Help
```shell
NAME:
torpedo - A tool to access AWS resources behind a VPCUSAGE:
torpedo [global options] command [command options] [arguments...]COMMANDS:
client, c Run the client command
server, s Run the server command
help, h Shows a list of commands or help for one commandGLOBAL OPTIONS:
--verbose (default: false)
--help, -h show help
```## Acknowledgements
This wasn't my idea! There is a much more fleshed out product called `7777` here: [https://port7777.com/](https://port7777.com/) by [Matthieu Napoli](https://mnapoli.fr/) and [Marco Aurélio Deleu](https://blog.deleu.dev/). `torpedo` works in a similar way but was rewritten in Go for faster bootup speeds and made open source for community contribution.