https://github.com/sr/kube-sentry-controller
Kubernetes CRDs and controller for managing Sentry teams, projects, and client keys
https://github.com/sr/kube-sentry-controller
kubernetes sentry
Last synced: 3 months ago
JSON representation
Kubernetes CRDs and controller for managing Sentry teams, projects, and client keys
- Host: GitHub
- URL: https://github.com/sr/kube-sentry-controller
- Owner: sr
- License: mit
- Created: 2018-12-25T22:48:44.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2023-03-06T23:44:22.000Z (over 3 years ago)
- Last Synced: 2025-01-02T15:44:51.888Z (over 1 year ago)
- Topics: kubernetes, sentry
- Language: Go
- Homepage:
- Size: 3.67 MB
- Stars: 3
- Watchers: 3
- Forks: 1
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# kube-sentry-controller
A set of Kubernetes [CustomResourceDefinition][crd] and a controller for managing Sentry teams, projects, and client keys.
[crd]: https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/
## Install
To install the `kube-sentry-controller` binary, run:
```
go get github.com/sr/kube-sentry-controller
```
Note that while the binary could be used as is, it is mainly provided as an example for how to use the `sentrycontroller` package. For production deployments you'd typically write your own main that integrates (metrics, logging, ...) with your existing infrastructure.
## Usage
Create a Sentry API Auth Token:
Configure the CRDs on the cluster:
```
kubectl apply -f config/crds
```
Run the controller:
```
kube-sentry-controller -api-token "${SENTRY_API_TOKEN}"
```
Create an example team, project, and client key:
```
sed -i "" "s,SENTRY_ORGANIZATION,my-org," config/samples/sentry.yaml
kubectl -f config/samples/sentry.yaml
```
Check that the controller has created a [secret](https://kubernetes.io/docs/concepts/configuration/secret/) with the SDN key:
```
kubectl get secrets example -o yaml
```
To clean-up, run:
```
kubectl destroy -f config/samples/sentry.yaml
```