{"id":13432875,"url":"https://github.com/ContainerSolutions/kubernetes-examples","last_synced_at":"2025-03-17T10:32:52.047Z","repository":{"id":37856718,"uuid":"268544645","full_name":"ContainerSolutions/kubernetes-examples","owner":"ContainerSolutions","description":"Minimal self-contained examples of standard Kubernetes features and patterns in YAML","archived":false,"fork":false,"pushed_at":"2023-10-03T10:18:57.000Z","size":338,"stargazers_count":1394,"open_issues_count":10,"forks_count":299,"subscribers_count":44,"default_branch":"master","last_synced_at":"2024-10-14T22:41:12.929Z","etag":null,"topics":["hacktoberfest","kubernetes","yaml"],"latest_commit_sha":null,"homepage":"https://k8s-examples.container-solutions.com/","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ContainerSolutions.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2020-06-01T14:26:42.000Z","updated_at":"2024-10-08T19:54:45.000Z","dependencies_parsed_at":"2023-01-29T15:45:57.694Z","dependency_job_id":"7d4b7cd0-e6ca-45ec-b7d7-d0c028c99b7b","html_url":"https://github.com/ContainerSolutions/kubernetes-examples","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContainerSolutions%2Fkubernetes-examples","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContainerSolutions%2Fkubernetes-examples/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContainerSolutions%2Fkubernetes-examples/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContainerSolutions%2Fkubernetes-examples/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ContainerSolutions","download_url":"https://codeload.github.com/ContainerSolutions/kubernetes-examples/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221675278,"owners_count":16861860,"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":["hacktoberfest","kubernetes","yaml"],"created_at":"2024-07-31T02:01:17.908Z","updated_at":"2024-10-27T12:31:28.599Z","avatar_url":"https://github.com/ContainerSolutions.png","language":"Shell","funding_links":[],"categories":["HarmonyOS","Shell","kubernetes","yaml"],"sub_categories":["Windows Manager"],"readme":"![yamllint](https://github.com/ContainerSolutions/kubernetes-examples/workflows/yamllint/badge.svg)\n# Kubernetes Examples\n\nA reference repository of YAML with canonical and as-simple-as-possible demonstrations of kubernetes functionality and features.\n\nSee here for a searchable front-end: https://k8s-examples.container-solutions.com/\n\n![Kubernetes Examples](logo.png)\n\n## Why?\n\nAt Container Solutions we find we regularly need chunks of YAML to  demonstrate something specific, such as:\n\n- A simple deployment\n\n- A simple pod\n\n- A pod with a volume\n\nThis might be to do a basic test of an environment, find an example to tinker with, or send to someone to get them going.\n\n## Usage\n\nThe examples can be used by a kubectl plugin `examples`. This plugin can be installed\nby [krew](https://krew.sigs.k8s.io/):\n\n- first [install krew](https://krew.sigs.k8s.io/docs/user-guide/setup/install/)\n- Install a custom plugin index: `kubectl krew index add cs https://github.com/ContainerSolutions/kubernetes-examples.git`\n- Install this plugin: `kubectl krew install cs/examples`\n\nInteractively discover by first selecting the resource type:\n```\n$ kubectl examples\n```\n\nfilter by resource type\n```\n$ kubectl examples Service\n```\n\nfilter by resource type and pattern\n```\n$ kubectl examples Pod res\n```\n\nIf there is only a single match selected by the parameters, it is printed to the stdout.\nSo you can deploy a modified version of a sample by:\n```\n$ export KUBE_EDITOR='code -w'\n$ kubectl examples Ingress fanout | kubectl create -f - --edit\n```\n\n## Sections\n\n`broken-*` - yamls that exemplify broken kubernetes yaml states\n\n`[A-Z][a-zA-Z]*` - Example yamls that correspond to resource types.\n\n`test` - Scripts to test or validate the YAML\n\nWithin those folders are either simple/canonical examples, or examples in subfolders that expose particular items of functionality that are highlighted by their yaml path, eg `Pod/spec.initContainers/`.\n\nIf an example is an exemplar of a particular feature but tightly related to another resource, then an absolute folder might be added eg in Service there is `Service/Pod.spec.subdomain`.\n\nSymlinks are also used to make finding things easier, eg `Service/headless-service -\u003e Service/spec.clusterIP`.\n\n`plugins` - a directory following the spec for a Custom krew [plugin index](https://krew.sigs.k8s.io/docs/user-guide/custom-indexes/)\n\n## Principles\n\nThe examples seek to be:\n\n- As simple as possible to illustrate the functionality\n\n- Self-contained (ie limited to one .yaml file)\n\n- Non-conflicting (eg resource names are unique)\n\n- Clear (eg resource names are verbose and unambiguous)\n\n## Release Process\n\nSee [here](RELEASE_PROCESS.md)\n\n## Sources / Thanks To\n\n[Official Kubernetes docs](https://kubernetes.io/docs/)\n\n[Kubernetes by Example](https://kubernetesbyexample.com/)\n\n[Practical Kubernetes](https://github.com/kubernauts/practical-kubernetes-problems)\n\n[Security Examples](https://github.com/NodyHub/docker-k8s-resources/tree/master/k8s-pods)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FContainerSolutions%2Fkubernetes-examples","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FContainerSolutions%2Fkubernetes-examples","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FContainerSolutions%2Fkubernetes-examples/lists"}