aws-secret-gen

command module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 15, 2023 License: MIT Imports: 5 Imported by: 0

README ยถ

Hello AWS Secret Generator! ๐Ÿ‘‹

์•ˆ๋…•ํ•˜์„ธ์š”! ํ•ด๋‹น ๋„๊ตฌ๋Š” Secret Manager์—์„œ ์ €์žฅ์ค‘์ธ Secret์„ ๊ฐ€์ ธ์™€์„œ ํŒŒ์ผ์˜ ํ˜•ํƒœ๋กœ ์ €์žฅํ•˜๋Š” ๋„๊ตฌ์ž…๋‹ˆ๋‹ค.

Hello! This tool is a tool that retrieves the secret stored in Secret Manager and saves it in the form of a file.

Why AWS Secret Generator? โš™๏ธ

AWS Secrets Manager๋Š” AWS์—์„œ ์ œ๊ณตํ•˜๋Š” Secret ๊ด€๋ฆฌ ๋„๊ตฌ์ž…๋‹ˆ๋‹ค. ํ•ด๋‹น ์„œ๋น„์Šค๋Š” ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค ์ž๊ฒฉ ์ฆ๋ช…, API ํ‚ค ๋ฐ ๊ธฐํƒ€ Secret์„ ์ˆ˜๋ช… ์ฃผ๊ธฐ ๋™์•ˆ ์‰ฝ๊ฒŒ ๋กœํ…Œ์ด์…˜ํ•˜๊ฑฐ๋‚˜, ๊ด€๋ฆฌ ๋ฐ ๊ฒ€์ƒ‰ํ•  ์ˆ˜ ์žˆ๋„๋ก ์ง€์›ํ•ฉ๋‹ˆ๋‹ค.

AWS Secrets Manager๋Š” is a secrets management service that helps you protect access to your applications, services, and IT resources. This service enables you to easily rotate, manage, and retrieve database credentials, API keys, and other secrets throughout their lifecycle.

ํ•ด๋‹น ๋„๊ตฌ๋ฅผ ์‚ฌ์šฉํ•˜๋ฉด Secret์„ ๊ด€๋ฆฌํ•˜๊ณ , Secret์„ ์‚ฌ์šฉํ•˜๋Š” ์„œ๋น„์Šค์—์„œ๋Š” Secret์„ ๊ฐ€์ ธ์™€์„œ ํŒŒ์ผ์˜ ํ˜•ํƒœ๋กœ ๋กœ์ปฌ PC์— ์ €์žฅํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

if you use this tool, you can manage your secret and get secret from AWS Secret Manager and save it as a file in your local PC.

๋ณด์•ˆ ์ƒ์˜ ์ด์œ ๋กœ AWS ์ฝ˜์†”์„ ๊ฐœ๋ฐœ์ž์—๊ฒŒ ์ œ๊ณตํ•˜์ง€ ์•Š๊ฑฐ๋‚˜, Slack๊ณผ ๊ฐ™์€ ๋ฉ”์‹ ์ €๋ฅผ ์ด์šฉํ•ด Secret์„ ๊ณต์œ ํ•˜๋Š” ํ˜•ํƒœ๋ฅผ ๋ฐฉ์ง€ํ•˜๊ณ ์ž ํ•ด๋‹น ๋„๊ตฌ๋ฅผ ๋งŒ๋“ค์—ˆ์Šต๋‹ˆ๋‹ค.

For security reasons, we do not provide AWS console to developers or prevent sharing secrets using messengers such as Slack.

Install with Go

ํ˜น์‹œ Golang์ด ์„ค์น˜๋˜์–ด ์žˆ์ง€ ์•Š๋‚˜์š”?

Do you have Golang installed?

$ go install github.com/YangTaeyoung/aws-secret-gen@v1.0.0

Usage ๐Ÿ› ๏ธ

Interface

$ aws-secret-gen -c <config path> -o <output path>
ํ”Œ๋ž˜๊ทธ ์„ค๋ช… ๊ธฐ๋ณธ ๊ฐ’
-c AWS Secret Generator์˜ Config๋ฅผ ์ €์žฅํ•˜๊ฑฐ๋‚˜, ๋ถˆ๋Ÿฌ์˜ฌ ์ฃผ์†Œ ~/.aws-secret-gen/config
-o AWS Secrets Manager์—์„œ ๊ฐ€์ ธ์˜จ Secrets๋ฅผ ์ €์žฅํ•  ํŒŒ์ผ ๊ฒฝ๋กœ (ํ™•์žฅ์ž๋ฅผ ํฌํ•จํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.) โœ… ๊ธฐ๋ณธ๊ฐ’ ์—†์Œ (required)
Flag Description Default
-c Save or load the Config of AWS Secret Generator ~/.aws-secret-gen/config
-o The file path to save the Secrets retrieved from AWS Secrets Manager (can include the extension.) โœ… No default value (required)

Trouble Shooting ๐Ÿ‘Š

zsh: command not found: aims-cli go๋กœ ์„ค์น˜ํ•œ ํ”„๋กœ๊ทธ๋žจ์„ ์‹คํ–‰ํ•  ๋•Œ ๋ฐœ์ƒํ•˜๋Š” ์—๋Ÿฌ์ž…๋‹ˆ๋‹ค. ~/.zshrc ํŒŒ์ผ(ํ˜น์€ ~/.bashrc)์˜ ํ•˜๋‹จ์— ๋‹ค์Œ๊ณผ ๊ฐ™์ด ํ™˜๊ฒฝ๋ณ€์ˆ˜๋ฅผ ์ถ”๊ฐ€ํ•ฉ๋‹ˆ๋‹ค.

error that occurs when running a program installed with go. Add the environment variable as follows at the bottom of the ~/.zshrc file (or ~/.bashrc).

# ...
export PATH="$HOME/go/bin:$PATH"

Documentation ยถ

The Go Gopher

There is no documentation for this package.

Directories ยถ

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL