Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Epic] Multi-tenant source control #875

Open
23 of 26 tasks
brendangadd opened this issue Feb 14, 2022 · 5 comments
Open
23 of 26 tasks

[Epic] Multi-tenant source control #875

brendangadd opened this issue Feb 14, 2022 · 5 comments
Assignees
Labels
area/engineering Requires attention from engineering: focus on foundational components or platform DevOps area/security kind/epic An epic priority/soon

Comments

@brendangadd
Copy link
Contributor

brendangadd commented Feb 14, 2022

As a user, I want to have easy access to Git source control management so that I can practice GitOps in my team even when working with sensitive data.

Broad strokes:

  1. Multi-tenant Gitea (instance per namespace)
  2. Look into PostgreSQL backend – probably a shared managed DB instance with a logical database per Gitea instance
  3. Kubernetes controller (profile) for automated deployment
  • Kubernetes resources
    • Network policy restricting to Gitea app?
    • Connectivity limited to ProB node pool
    • X509 cert auth with PostgreSQL via Spiffe? No, per @blairdrummond's comment below
  • PostgreSQL database creation etc.
  1. Gitea upgrades over time – via controller?
  2. Copy/paste architecture to unclassified context

Roadmap to Production

Local Development (5 day)

Profile Controller SQlite Deployment (5 day)

Create Managed DB (5 day)

Automate Interaction with Database (10 day)

UI Enhancements

Finalize the Deployment (16 day)

Protected-b

Production

Docs

Advantages

  • Increased security via namespace isolation
  • Increased collaboration with external users
  • Future compatibility with MLOps (seldon model deployments, convention based)
    • With a shared gitlab instance, you would need to add a layer that references specific locations in gitlab with access tokens or equivalent to try and set this up, but per-namespace gitea handles this more elegantly and simply.
  • If your namespace has any external user, you are forbidden from using gitlab
@brendangadd brendangadd added kind/feature New feature or request area/engineering Requires attention from engineering: focus on foundational components or platform DevOps area/security priority/soon labels Feb 14, 2022
@blairdrummond
Copy link
Contributor

Plain postgres auth will probably be ok (instead of spiffe)! We might want the controller to create postgres secrets and possibly rotate those secrets on occasion (fixed interval).

@sylus
Copy link
Member

sylus commented Feb 28, 2022

Out of curiousity can I get some further information on this? @blairdrummond

a) This won't take away resources from KF 1.3 and notebook culling which really needs to happen to Prod soon?
b) What was the point of gitlab protected b and just using RBAC there for isolation is it not strict enough?
c) Will gitlab be removed in favor of this design?
d) Not every namespace will be given this correct as gitea requires 2 cores and 1.5GB of memory so the cluster cost would be quite high for every namespace

@blairdrummond
Copy link
Contributor

blairdrummond commented Feb 28, 2022

a) KF 1.3 will not be affected, @cboin1996 is independent of that
b) Yeah this is in-part to do unclassified & protected-b
c) Yes, Gitlab will be removed
d) @sylus I think we'll dial the CPU way back (maybe half a cpu?). We might only apply Gitea to shared-namespaces, we have labels in-place that allow that.

@blairdrummond
Copy link
Contributor

@brendangadd @chritter I am realizing, this shared postgres + namespaced deployment setup, would enable MLFlow very very quickly. You could basically copy-paste the deployment for MLFlow.

@chuckbelisle
Copy link
Contributor

This Epic is being blocked by Cyber Sec priorities and new platform requirements being introduced. All is in place to have this deployed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/engineering Requires attention from engineering: focus on foundational components or platform DevOps area/security kind/epic An epic priority/soon
Projects
None yet
Development

No branches or pull requests

5 participants