Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/noahingh/sweeper
Sweeper is a tool to support developers organize the emphemeral environment on Kubernetes.
https://github.com/noahingh/sweeper
emphemeral k8s kubernetes
Last synced: 5 days ago
JSON representation
Sweeper is a tool to support developers organize the emphemeral environment on Kubernetes.
- Host: GitHub
- URL: https://github.com/noahingh/sweeper
- Owner: noahingh
- License: apache-2.0
- Created: 2020-07-05T08:30:40.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-07-28T17:21:10.000Z (over 4 years ago)
- Last Synced: 2024-11-30T06:06:36.645Z (2 months ago)
- Topics: emphemeral, k8s, kubernetes
- Language: Go
- Homepage:
- Size: 291 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
![sweeper](./docs/img/sweeper.jpeg)
# Sweeper
[![GoDoc](https://godoc.org/github.com/hanjunlee/sweeper?status.svg)](https://pkg.go.dev/github.com/hanjunlee/sweeper)
---
Sweeper is a tool to support developers organize the emphemeral environment on Kubernetes.
## Concept
In many compnies, the environment of development is organized with the static environment, for example, we might have the following environment: `dev`, `staging`, `prod`. But as the time goes the static environment has [some issues](https://pipelinedriven.org/article/the-four-biggest-issues-with-having-static-environments). To cover these issues, the **ephemeral environment** could be one of solutions.
The emphemeral envrionment contains two extra actions: one at the beginning, and one at the end, that spin up an environment for a purpose, and spin down an environment at the end. Sweeper is contained in the spin-down step, It cleans up selected resources after the TTL time. For example, if you apply a `deployment` and a `service`, which is kubernetes resource, the sweeper will delete resources which is labeled after the ttl time you defined.
## Installation
1. Create the kubernetes CRD.
```shell
$ kustomize build config/crd | kubectl apply -f -$ kubectl api-resources | grep sweeper
kubernetes selector.sweeper.io true Kubernetes
...
```2. Install the controller.
```shell
$ kustomize build config/manager | kubectl apply -f -
```## Usage
### Kubernetes
The `kubernetes` resource is active in the namespace which has the label `sweeper.io/enabled=true`. You should set the label the namespace which you want to activate like below.
```shell
$ kubectl label ns sweeper sweeper.io/enabled=true --overwrite
```Create the `kubernetes` manifest on the namespace. You reference the sample directory(in `./config/samples`) and also you can read [godoc]().
## Contribute
TBD
## License
TBD