nstrug / MutateMate

This is a mutating web hook implemantation

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Mutate Mate

Kubernetes Mutating Webhook Iplementation for Secrets and Resource Management(CPU, RAM, GPU)

At our company we are using a tool for Data Science operations. This tool has flaws. To fix that we thought using Mutating Web Hooks is a great option.

If you are using Opendatahub and Elyra Pipelines or some tools build on that, you are having this issue.

This API's kubernetes project will have multiple secret definitons in that project. At the webhook call, first we will look for project defitions. Definitions has key words with hashtags (like "lore ipsum #secret1 #secret2"). These will determine which secrets will ve injected to Notebook or Pipeline CRDs. As a second step, if the call is for Elyra Pipelines; API will get the limitations for project and apply the same settings to Elyra Pipelines every step.

This way secrets will be auto assigned and will be at single namespace. Elyra Pipelines is resource and secrets will be installed automatically with no manuel operation.

If you have same problem, I hope this will solve your problem too.

Thanks

This project is possible with @ckavili help. Thank you

ProTip: Access Token

To get the access token for local debug; goto mutatemateapi pod and at the terminal write this command:

cat /run/secrets/kubernetes.io/serviceaccount/token

About

This is a mutating web hook implemantation


Languages

Language:Python 98.1%Language:Dockerfile 1.9%