{"id":27881828,"url":"https://github.com/src-d/k8s-pod-headless-service-operator","last_synced_at":"2025-05-05T05:05:32.383Z","repository":{"id":64302042,"uuid":"192750795","full_name":"src-d/k8s-pod-headless-service-operator","owner":"src-d","description":null,"archived":false,"fork":false,"pushed_at":"2019-08-28T12:47:48.000Z","size":3976,"stargazers_count":7,"open_issues_count":0,"forks_count":5,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-05T05:05:24.394Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/src-d.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-06-19T14:41:09.000Z","updated_at":"2025-04-13T05:31:55.000Z","dependencies_parsed_at":"2023-01-15T09:30:46.396Z","dependency_job_id":null,"html_url":"https://github.com/src-d/k8s-pod-headless-service-operator","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/src-d%2Fk8s-pod-headless-service-operator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/src-d%2Fk8s-pod-headless-service-operator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/src-d%2Fk8s-pod-headless-service-operator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/src-d%2Fk8s-pod-headless-service-operator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/src-d","download_url":"https://codeload.github.com/src-d/k8s-pod-headless-service-operator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252442485,"owners_count":21748451,"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":[],"created_at":"2025-05-05T05:05:31.835Z","updated_at":"2025-05-05T05:05:32.376Z","avatar_url":"https://github.com/src-d.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Kubernetes Pod Headless Service Operator\nThis is a Kubernetes operator that watches Pods with the annotation `srcd.host/create-headless-service: \"true\"`, if this annotation is found the operator will create a Headless Service with the pod's name and an Endpoint pointing to the Pod IP. This allows for the Pod's hostname to be resolvable by DNS, this is a requirement needed by certain applications.\n\n## Limitations\nThis will only work if your Pod's name is maximum 63 characters as this is the maximum length for a service name.\n\n# Installation\n\nThis tool is made to run in cluster as a Deployment. For testing purposes it can also run locally with a connection to a Kubernetes cluster.\n\n## Kubernetes manifests\nThis repository provides example manifests file you can use to deploy this. These contain a service account and RBAC configuration for the tool to be able to read Pods and read/write Services. As well as a Deployment to deploy the operator in a cluster.\n```bash\n~ $ cd manifests\n~ $ kubectl apply -f rbac.yaml\n~ $ kubectl apply -f daemonset.yaml\n```\n\n## Helm\nWe also provide a Helm chart in our [Charts repository](https://github.com/src-d/charts). \n```bash\n~ $ helm repo add srcd-infra https://src-d.github.io/charts/infra/\n~ $ helm install k8s-pod-headless-service-operator --set image.tag=v0.1.1\n```\n\n# Configuration\n\n* envvar: `NAMESPACE` flag: `--namespace` The namespace to watch, by default it watches all namespaces\n* envvar: `POD_ANNOTATION` flag: `--pod-annotation` Pod annotation that needs to be set to `true` to be picked up by the operator. Default: `srcd.host/create-headless-service`\n* envvar: `KUBERNETES_CONTEXT` flag: `--context` If this is set it will not attempt to load the in-cluster service account but loads the context value out of `$HOME/.kube/config`\n\n# Contribute\n\n[Contributions](https://github.com/src-d/k8s-pod-headless-service-operator/issues) are more than welcome, if you are interested please take a look to\nour [Contributing Guidelines](CONTRIBUTING.md).\n\n# Code of Conduct\n\nAll activities under source{d} projects are governed by the [source{d} code of conduct](.github/CODE_OF_CONDUCT.md).\n\n# License\nApache License Version 2.0, see [LICENSE](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsrc-d%2Fk8s-pod-headless-service-operator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsrc-d%2Fk8s-pod-headless-service-operator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsrc-d%2Fk8s-pod-headless-service-operator/lists"}