{"id":26088727,"url":"https://github.com/cybozu-go/accurate","last_synced_at":"2025-04-12T04:23:06.598Z","repository":{"id":42037609,"uuid":"380416891","full_name":"cybozu-go/accurate","owner":"cybozu-go","description":"Kubernetes controller for multi-tenancy.  It propagates resources between namespaces accurately and allows tenant users to create/delete sub-namespaces.","archived":false,"fork":false,"pushed_at":"2024-10-18T00:16:23.000Z","size":2258,"stargazers_count":38,"open_issues_count":7,"forks_count":5,"subscribers_count":14,"default_branch":"main","last_synced_at":"2024-10-20T11:35:13.607Z","etag":null,"topics":["kubectl-plugins","kubernetes","multi-tenancy"],"latest_commit_sha":null,"homepage":"https://cybozu-go.github.io/accurate/","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cybozu-go.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-06-26T04:57:47.000Z","updated_at":"2024-10-18T00:16:26.000Z","dependencies_parsed_at":"2023-10-23T06:21:10.630Z","dependency_job_id":"e8a787a1-cfa7-4e94-b9fe-f78bb0f914d5","html_url":"https://github.com/cybozu-go/accurate","commit_stats":null,"previous_names":[],"tags_count":38,"template":false,"template_full_name":"cybozu-go/neco-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cybozu-go%2Faccurate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cybozu-go%2Faccurate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cybozu-go%2Faccurate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cybozu-go%2Faccurate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cybozu-go","download_url":"https://codeload.github.com/cybozu-go/accurate/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248514650,"owners_count":21117003,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["kubectl-plugins","kubernetes","multi-tenancy"],"created_at":"2025-03-09T08:12:58.950Z","updated_at":"2025-04-12T04:23:06.579Z","avatar_url":"https://github.com/cybozu-go.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![GitHub release](https://img.shields.io/github/release/cybozu-go/accurate.svg?maxAge=60)][releases]\n[![CI](https://github.com/cybozu-go/accurate/actions/workflows/ci.yaml/badge.svg)](https://github.com/cybozu-go/accurate/actions/workflows/ci.yaml)\n[![PkgGoDev](https://pkg.go.dev/badge/github.com/cybozu-go/accurate?tab=overview)](https://pkg.go.dev/github.com/cybozu-go/accurate?tab=overview)\n[![Go Report Card](https://goreportcard.com/badge/github.com/cybozu-go/accurate)](https://goreportcard.com/report/github.com/cybozu-go/accurate)\n\n# Accurate\n\nAccurate is a Kubernetes controller for soft multi-tenancy environments.\n\nAccurate resembles [Hierarchical Namespace Controller (HNC)][HNC].\nIt propagates resources between namespaces and allows tenant users to create/delete sub-namespaces.\n\n## Features\n\n- Resource propagation between namespaces\n    - Any namespace-scoped resource can be propagated.\n    - ⚠️ Generated resources can be automatically checked and propagated. (DEPRECATED)\n- Inheriting labels and annotations from parent namespaces\n- Template namespaces\n- SubNamespace custom resource for tenant users\n- `kubectl` plugin\n\n## Comparison to Hierarchical Namespace Controller (HNC)\n\nBoth Accurate and HNC aim the same goal -- to provide better namespace usability on soft multi-tenancy Kubernetes environments.\n\nAccurate is more accurate than HNC in propagating resources because Accurate adopts an opt-in manner while HNC adopts an opt-out manner.\nWith Accurate, only resources annotated with `accurate.cybozu.com/propagate` will be propagated.\nWith HNC, all resources will be propagated except for ones that are specially annotated.\n\nSuppose you want to propagate only [a Secret for pulling private images](https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/).\nWith HNC, this can be quite difficult because Secrets are often generated from another resource.\nSuch generated Secrets are often not possible to have custom annotations.\nAs a consequence, such Secrets would be propagated to sub-namespaces, which may cause security problems.\n\nThere are many other differences between Accurate and HNC.\nPlease check them in [the documentation][doc].\n\n## Demo\n\nRun and try Accurate on a [kind (Kubernetes-In-Docker)][kind] cluster as follows:\n\n1. Prepare a Linux box running Docker.\n2. Checkout this repository.\n\n    ```console\n    $ git clone https://github.com/cybozu-go/accurate\n    ```\n\n3. Install [aqua][].\n\n    ```console\n    $ go install github.com/aquaproj/aqua/v2/cmd/aqua@latest\n    ```\n\n    cf. https://aquaproj.github.io/docs/install\n \n4. Go to `e2e` directory, setup shell variables, and execute `make start`.\n\n    ```console\n    $ cd e2e\n    $ PATH=$(cd ..; pwd)/bin:$PATH\n    $ KUBECONFIG=$(pwd)/.kubeconfig\n    $ export KUBECONFIG\n    $ make start\n    ```\n\n5. Create a root namespace and a sub-namespace using `kubectl accurate`.\n\n    ```console\n    $ kubectl create ns root1\n    $ kubectl accurate ns set-type root1 root\n    $ kubectl accurate sub create sub1 root1\n    $ kubectl accurate list\n    $ kubectl accurate ns describe root1\n    $ kubectl accurate ns describe sub1\n    ```\n\n6. Create a Secret in `root1` and see it will be propagated to `sub1`.\n\n    ```console\n    $ kubectl -n root1 create secret generic s1 --from-literal=foo=bar\n    $ kubectl -n root1 annotate secrets s1 accurate.cybozu.com/propagate=update\n    $ sleep 1\n    $ kubectl -n sub1 get secrets\n    ```\n\n7. Stop the kind cluster.\n\n    ```console\n    $ make stop\n    ```\n\n## Documentation\n\nRead the documentation at https://cybozu-go.github.io/accurate/ .\n\n[releases]: https://github.com/cybozu-go/accurate/releases\n[HNC]: https://github.com/kubernetes-sigs/hierarchical-namespaces\n[doc]: https://cybozu-go.github.io/accurate\n[kind]: https://kind.sigs.k8s.io/\n[aqua]: https://aquaproj.github.io\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcybozu-go%2Faccurate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcybozu-go%2Faccurate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcybozu-go%2Faccurate/lists"}