{"id":15571398,"url":"https://github.com/hatamiarash7/kubernetes-redis","last_synced_at":"2026-05-05T12:33:28.473Z","repository":{"id":40480983,"uuid":"246591810","full_name":"hatamiarash7/Kubernetes-Redis","owner":"hatamiarash7","description":"Deploy Redis cluster in Kubernetes","archived":false,"fork":false,"pushed_at":"2023-09-05T06:10:57.000Z","size":52,"stargazers_count":2,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-29T06:31:19.298Z","etag":null,"topics":["cluster","clustering","database","kubernetes","redis","redis-cluster","redis-database","replica","replica-set"],"latest_commit_sha":null,"homepage":"https://arash-hatami.ir/redis-cluster-in-kubernetes/","language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hatamiarash7.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":"2020-03-11T14:21:39.000Z","updated_at":"2022-06-26T13:55:38.000Z","dependencies_parsed_at":"2024-10-02T18:00:29.698Z","dependency_job_id":"d3b1a909-17a2-4c66-9130-a14b8035146e","html_url":"https://github.com/hatamiarash7/Kubernetes-Redis","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hatamiarash7/Kubernetes-Redis","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatamiarash7%2FKubernetes-Redis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatamiarash7%2FKubernetes-Redis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatamiarash7%2FKubernetes-Redis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatamiarash7%2FKubernetes-Redis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hatamiarash7","download_url":"https://codeload.github.com/hatamiarash7/Kubernetes-Redis/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatamiarash7%2FKubernetes-Redis/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32649579,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-05T11:29:49.557Z","status":"ssl_error","status_checked_at":"2026-05-05T11:29:48.587Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5: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":["cluster","clustering","database","kubernetes","redis","redis-cluster","redis-database","replica","replica-set"],"created_at":"2024-10-02T18:00:15.854Z","updated_at":"2026-05-05T12:33:28.455Z","avatar_url":"https://github.com/hatamiarash7.png","language":"Dockerfile","funding_links":["https://ko-fi.com/D1D1WGU9"],"categories":[],"sub_categories":[],"readme":"# Kubernetes Redis Cluster\n\n Deploy Redis cluster in Kubernetes\n\n![DockerImage-Github](https://github.com/hatamiarash7/Kubernetes-Redis/workflows/DockerImage-Github/badge.svg) ![DockerImage-Dockerhub](https://github.com/hatamiarash7/Kubernetes-Redis/workflows/DockerImage-Dockerhub/badge.svg)\n\n## Install\n\n\u003cdiv dir=\"rtl\"\u003e\nکاربران فارسی زبان جهت اطلاعات بیشتر به این پست مراجعه کنند :\n\n[راه اندازی کلاستر Redis](https://arash-hatami.ir/redis-cluster-in-kubernetes/)\n\u003c/div\u003e\n\nRedis Cluster requires at least 3 master nodes, so we have 6 replicas here ( 3 master / 3 slave )\n\n```bash\nkubectl apply -f statefulset.yml\nkubectl apply -f service.yml\n```\n\n## Make cluster\n\nYou should scale the cluster up or down manually\n\n### Get cluster nodes\n\n```bash\nkubectl get pods -l app=redis-cluster -o jsonpath='{range.items[*]}{.status.podIP}:6379 '\n```\n\nNow we are going to create the cluster ( assign master/slave roles, distribute slot maps) using the `redis-cli --cluster create` script.  \n\nSince we are going create 3 masters cluster with 3 dedicated slaves, the `--cluster-replicas 1` flag is passed.\n\n```bash\nkubectl exec -it redis-cluster-0 -- redis-cli --cluster create --cluster-replicas 1 \u003c\u003c\u003c node list from previous command \u003e\u003e\u003e\n```\n\nOr you can merge command like this :\n\n```bash\nkubectl exec -it redis-cluster-0 -- redis-cli --cluster create --cluster-replicas 1 $(kubectl get pods -l app=redis-cluster -o jsonpath='{range.items[*]}{.status.podIP}:6379 ')\n```\n\n---\n\n## Support\n\n[![ko-fi](https://www.ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/D1D1WGU9)\n\n\u003cdiv\u003e\u003ca href=\"https://payping.ir/@hatamiarash7\"\u003e\u003cimg src=\"https://cdn.payping.ir/statics/Payping-logo/Trust/blue.svg\" height=\"128\" width=\"128\"\u003e\u003c/a\u003e\u003c/div\u003e\n\n## Contributing\n\n1. Fork it !\n2. Create your feature branch : `git checkout -b my-new-feature`\n3. Commit your changes : `git commit -am 'Add some feature'`\n4. Push to the branch : `git push origin my-new-feature`\n5. Submit a pull request :D\n\n## Issues\n\nEach project may have many problems. Contributing to the better development of this project by reporting them.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhatamiarash7%2Fkubernetes-redis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhatamiarash7%2Fkubernetes-redis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhatamiarash7%2Fkubernetes-redis/lists"}