https://github.com/shini4i/kd
A bash script that makes it easy to view the contents of secrets stored in a Kubernetes cluster.
https://github.com/shini4i/kd
bash-script kubectl kubernetes kubernetes-secrets
Last synced: 6 months ago
JSON representation
A bash script that makes it easy to view the contents of secrets stored in a Kubernetes cluster.
- Host: GitHub
- URL: https://github.com/shini4i/kd
- Owner: shini4i
- License: mit
- Created: 2022-07-04T22:00:31.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2024-06-13T20:52:53.000Z (about 2 years ago)
- Last Synced: 2025-04-17T20:39:35.796Z (about 1 year ago)
- Topics: bash-script, kubectl, kubernetes, kubernetes-secrets
- Language: Shell
- Homepage:
- Size: 19.5 KB
- Stars: 7
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# kd
Kubernetes secrets Decoder



`kd` is a bash script that decodes Kubernetes secrets. It makes it easy to view the contents of secrets stored in a Kubernetes cluster.
There are alternatives to this script, but they are either not maintained or require way too many dependencies.
## Prerequisites
Before you can use `kd`, you need to have the following installed:
- `kubectl`: the Kubernetes command-line tool
- `yq`: a YAML parser and processor
## Installation
### Option 1: Install with Homebrew (macOS and Linux)
If you're using macOS or Linux, you can install `kd` using Homebrew. To do so, run the following command:
```bash
brew install shini4i/tap/kd
```
### Option 2: Install manually
To install `kd` manually, download the `src/kd.sh` script and add it to your PATH. You can do this by running the following commands:
```bash
curl https://raw.githubusercontent.com/shini4i/kd/main/src/kd.sh -o kd
chmod +x kd
sudo mv kd /usr/local/bin/
````
## Usage
Here are some examples of how to use kd:
```bash
# Decode a secret in the current namespace
kd my-secret
# Decode a secret in a specific namespace
kd my-secret my-namespace
```
## Contributing
Contributions to `kd` are welcome! Please open an issue or a pull request if you find a bug or want to submit a patch.
New feature requests are not expected, but suggestions for improving the existing functionality or fixing bugs are appreciated.