Skip to content

Commit

Permalink
add deployment files for rook kubernetes
Browse files Browse the repository at this point in the history
  • Loading branch information
Crapworks committed Feb 14, 2020
1 parent 0b25745 commit edb47f6
Show file tree
Hide file tree
Showing 4 changed files with 67 additions and 0 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ ceph-dash - a free ceph dashboard / monitoring api

- [ceph-dash - a free ceph dashboard / monitoring api](#user-content-ceph-dash---a-free-ceph-dashboard--monitoring-api)
- [Newest Feature](#user-content-newest-feature)
- [Rook on Kubernetes](#user-content-root-on-kubernetes)
- [Docker Container](#user-content-docker-container)
- [InfluxDB support](#user-content-influxdb-support)
- [Old content warning](#user-content-old-content-warning)
Expand All @@ -28,6 +29,10 @@ You can find a blog entry regarding monitoring a Ceph cluster with ceph-dash on
Newest Feature
--------------

### Root on Kubernetes

I recently played around with [Rook](https://rook.io/) on [Kubernetes](https://kubernetes.io/). This was so far my fastest Ceph cluster to setup. Since Rook provides some secrets and config maps already, I made the docker container for Ceph-dash compatible with their format. I also added Kubernetes deployment files in the contrib folder (tested on [GKE](https://cloud.google.com/kubernetes-engine), but should work on any Kubernetes cluster). No need to configure anything, they should just work out of the box.

### Docker container

Since everybody recently seems to be hyped as hell about the container stuff, I've decided that I can contribute to that with a ready-to-use docker container. Available at [Docker Hub](https://hub.docker.com/r/crapworks/ceph-dash/) you can pull the ceph-dash container and configure it via the following environment variables:
Expand Down
9 changes: 9 additions & 0 deletions contrib/rook/ceph-dash-ingress.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: ceph-dash
namespace: rook-ceph
spec:
backend:
serviceName: ceph-dash
servicePort: 5000
13 changes: 13 additions & 0 deletions contrib/rook/ceph-dash-service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
apiVersion: v1
kind: Service
metadata:
name: ceph-dash
namespace: rook-ceph
spec:
type: NodePort
selector:
app: ceph-dash
ports:
- protocol: TCP
port: 5000
targetPort: 5000
40 changes: 40 additions & 0 deletions contrib/rook/ceph-dash.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: ceph-dash
namespace: rook-ceph
labels:
app: ceph-dash
spec:
selector:
matchLabels:
app: ceph-dash
template:
metadata:
labels:
app: ceph-dash
spec:
containers:
- image: crapworks/ceph-dash:v1.5
name: ceph-dash
ports:
- containerPort: 5000
protocol: TCP
resources:
requests:
memory: "300Mi"
cpu: "100m"
limits:
memory: "500Mi"
cpu: "200m"
env:
- name: CEPHMONS
valueFrom:
configMapKeyRef:
name: rook-ceph-mon-endpoints
key: data
- name: KEYRING
valueFrom:
secretKeyRef:
name: rook-ceph-mons-keyring
key: keyring

0 comments on commit edb47f6

Please sign in to comment.