{"id":37176539,"url":"https://github.com/sthlmio/preemptible-sentinel","last_synced_at":"2026-01-14T20:35:57.195Z","repository":{"id":64302547,"uuid":"194545650","full_name":"sthlmio/preemptible-sentinel","owner":"sthlmio","description":"Preemptible Sentinel (Controller), deployed to a GKE cluster it will monitor the Preemptible nodes used in the cluster and drain and delete nodes gracefully that are created close to each other, to prevent large disruptions when GKE automatically kills the nodes after 24h.","archived":true,"fork":false,"pushed_at":"2023-02-25T00:31:48.000Z","size":9905,"stargazers_count":3,"open_issues_count":4,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-08T00:39:43.928Z","etag":null,"topics":["gke","golang","google-cloud","google-cloud-platform","kubernetes","preemptibles"],"latest_commit_sha":null,"homepage":"","language":"Go","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/sthlmio.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-06-30T17:58:37.000Z","updated_at":"2025-05-16T17:58:50.000Z","dependencies_parsed_at":"2024-06-20T12:01:02.196Z","dependency_job_id":"342c5074-2b1a-4110-813b-4a63186c6c4f","html_url":"https://github.com/sthlmio/preemptible-sentinel","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/sthlmio/preemptible-sentinel","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sthlmio%2Fpreemptible-sentinel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sthlmio%2Fpreemptible-sentinel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sthlmio%2Fpreemptible-sentinel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sthlmio%2Fpreemptible-sentinel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sthlmio","download_url":"https://codeload.github.com/sthlmio/preemptible-sentinel/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sthlmio%2Fpreemptible-sentinel/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28434483,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T18:57:19.464Z","status":"ssl_error","status_checked_at":"2026-01-14T18:52:48.501Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["gke","golang","google-cloud","google-cloud-platform","kubernetes","preemptibles"],"created_at":"2026-01-14T20:35:56.548Z","updated_at":"2026-01-14T20:35:57.186Z","avatar_url":"https://github.com/sthlmio.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# preemptible-sentinel\n\n[![Build Status](https://travis-ci.org/sthlmio/preemptible-sentinel.svg?branch=master)](https://travis-ci.org/sthlmio/preemptible-sentinel)\n\nThis is a very simple Preemptible Sentinel (Controller), deployed to a GKE cluster it will monitor the Preemptible nodes used in the cluster and drain and delete nodes gracefully that are created close to each other, to prevent large disruptions when GKE automatically kills the nodes after 24h.\n\nThe controller is under development and should not be considered stable until we reach version `1.0`.\n\n#### We use this in conjuction with:\n- [estafette-gke-node-pool-shifter](https://github.com/estafette/estafette-gke-node-pool-shifter)\n    - Shifting node pool from the backup node pool to our preemptible node pool if the autoscaler creates these backup nodes for some reason\n- [k8s-node-termination-handler](https://github.com/GoogleCloudPlatform/k8s-node-termination-handler)\n    - Used when GKE terminates a preemptible node so the node gracefully evicts all pods before deletion\n\n#### Usage example:\n- **Static node pool** (2 or more nodes for special workloads)\n    - Perfect for special workload like ingresses, to avoid nodes entering and leaving load balancers etc. Or other very important workloads that always needs to be running\n- **Preemptible node pool** (5-7 nodes using autoscaling)\n    - Running all HA workloads by default\n- **Backup node pool** (0-7 nodes using autoscaling)\n    - Backup nodes if preemptible nodes should be out of stock\n    \n#### Install\nAdd sthlmio chart repository before installing the chart. Also the chart is installed with `--devel` flag to allow semver versions like `0.1.0-alpha.0` until we reach stable `1.0.0`.\n```bash\nhelm repo add sthlmio https://charts.sthlm.io\n\nhelm install \\\n    --name preemptible-sentinel \\\n    --namespace sthlmio \\\n    --devel \\\n    sthlmio/preemptible-sentinel\n```\n\n#### Development\nThe development of the chart can only be done against a GKE cluster with a node pool of regular vms and a node pool of preemptible vms.\nWe use `go1.12`, good commands to keep in mind:\n\n```bash\ngo build\ngo test -v ./...\ngo mod tidy\ngo mod vendor\n```\n\n##### Fast local development against GKE cluster\nMake sure that current context is against the cluster to test against\n`kubectl config set-context $(kubectl config current-context)`\n```bash\nmake \u0026\u0026 ./controller\n```\n\n##### Build/push/deploy for local development\n```bash\nexport PRIVATE_DOCKER_REPO=\u003cyour private docker repo\u003e\n\ndocker build --no-cache -t $(PRIVATE_DOCKER_REPO):latest .\ndocker push $(PRIVATE_DOCKER_REPO):latest\nhelm install \\\n    --name preemptible-sentinel \\\n    --namespace sthlmio \\\n    --set-string repository=$(PRIVATE_DOCKER_REPO) \\\n    --set-string tag=latest \\\n    --set-string pullPolicy=Always \\\n    ./chart/preemptible-sentinel\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsthlmio%2Fpreemptible-sentinel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsthlmio%2Fpreemptible-sentinel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsthlmio%2Fpreemptible-sentinel/lists"}