text stringlengths 0 59.1k |
|---|
ports: |
- containerPort: 26379 |
<|endoftext|> |
# source: k8s_examples/_archived/storage/redis/redis-sentinel-service.yaml type: yaml |
apiVersion: v1 |
kind: Service |
metadata: |
labels: |
name: sentinel |
role: service |
name: redis-sentinel |
spec: |
ports: |
- port: 26379 |
targetPort: 26379 |
selector: |
redis-sentinel: "true" |
<|endoftext|> |
# source: k8s_examples/_archived/storage/redis/redis-master.yaml type: yaml |
apiVersion: v1 |
kind: Pod |
metadata: |
labels: |
name: redis |
redis-sentinel: "true" |
role: master |
name: redis-master |
spec: |
containers: |
- name: master |
image: registry.k8s.io/redis:v1 |
env: |
- name: MASTER |
value: "true" |
ports: |
- containerPort: 6379 |
resources: |
limits: |
cpu: "0.1" |
volumeMounts: |
- mountPath: /redis-master-data |
name: data |
- name: sentinel |
image: registry.k8s.io/redis:v1 |
env: |
- name: SENTINEL |
value: "true" |
ports: |
- containerPort: 26379 |
volumes: |
- name: data |
emptyDir: {} |
<|endoftext|> |
# source: k8s_examples/_archived/storage/redis/redis-controller.yaml type: yaml |
apiVersion: v1 |
kind: ReplicationController |
metadata: |
name: redis |
spec: |
replicas: 1 |
selector: |
name: redis |
template: |
metadata: |
labels: |
name: redis |
role: master |
spec: |
containers: |
- name: redis |
image: registry.k8s.io/redis:v1 |
ports: |
- containerPort: 6379 |
resources: |
limits: |
cpu: "0.1" |
volumeMounts: |
- mountPath: /redis-master-data |
name: data |
volumes: |
- name: data |
<|endoftext|> |
# source: k8s_examples/_archived/storage/redis/README.md type: docs |
## Reliable, Scalable Redis on Kubernetes |
The following document describes the deployment of a reliable, multi-node Redis on Kubernetes. It deploys a master with replicated slaves, as well as replicated redis sentinels which are used for health checking and failover. |
### Prerequisites |
This example assumes that you have a Kubernetes cluster installed and running, and that you have installed the ```kubectl``` command line tool somewhere in your path. Please see the [getting started](https://kubernetes.io/docs/getting-started-guides/) for installation instructions for your platform. |
### A note for the impatient |
This is a somewhat long tutorial. If you want to jump straight to the "do it now" commands, please see the [tl; dr](#tl-dr) at the end. |
### Turning up an initial master/sentinel pod. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.