openebs

command
v4.0.0-beta+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 9, 2018 License: Apache-2.0, Apache-2.0 Imports: 15 Imported by: 0

README

OpenEBS Kubernetes PV provisioner

About OpenEBS

OpenEBS is containerized storage for containers. More details on OpenEBS can be found on OpenEBS project page. OpenEBS Kubernetes PV provisioner is using API's exposed by maya-apiserver to perform provision and delete operation.

Building OpenEBS provisioner from source

Generate openebs-provisioner binary

Following command will generate openebs-provisioner binary in external-storage/openebs.

$ make openebs
Create a docker image on local
$ make push-openebs-provisioner
Push OpenEBS provisioner image to docker hub

To push docker image to docker hub you need to have docker hub login credentials. You can pass docker credentials and image name as a environment variable.

$ export DIMAGE="docker-username/imagename"
$ export DNAME="docker-username"
$ export DPASS="docker-hub-password"
$ make deploy-openebs-provisioner

Running OpenEBS provisioner in kubernetes cluster

OpenEBS provisioner is one of the component of OpenEBS Operator. You can run OpenEBS provisioner by starting the OpenEBS operator.

$ kubectl apply -f https://raw.githubusercontent.com/openebs/openebs/master/k8s/openebs-operator.yaml

If you want to run specific version of OpenEBS provisioner then you need to follow steps given below:

  • Create OpenEBS Provisioner as kubernetes deployment object in OpenEBS Operator.
---

apiVersion: apps/v1beta1
kind: Deployment
metadata:
  name: openebs-provisioner
  namespace: openebs
spec:
  replicas: 1
  template:
    metadata:
      labels:
        name: openebs-provisioner
    spec:
      serviceAccountName: openebs-maya-operator
      containers:
      - name: openebs-provisioner
        imagePullPolicy: Always
        image: openebs/openebs-k8s-provisioner:0.3-RC2
        env:
        - name: NODE_NAME
          valueFrom:
            fieldRef:
              fieldPath: spec.nodeName
        - name: OPENEBS_NAMESPACE
          valueFrom:
            fieldRef:
              fieldPath: metadata.namespace

---
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
   name: openebs-jupyter
provisioner: openebs.io/provisioner-iscsi
parameters:
  pool: hostdir-var
  replica: "2"
  size: 5G
  • You can claim this volume by setting above storageclass in PersistentVolumeClaim Specs. Please refer demo-jupyter-openebs.yaml
---
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
  name: jupyter-data-vol-claim
spec:
  storageClassName: openebs-jupyter
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 5G
---
apiVersion: v1
kind: Service
metadata:
  name: jupyter-service
spec:
  ports:
  - name: ui
    port: 8888
    nodePort: 32424
    protocol: TCP
  selector:
    name: jupyter-server
  sessionAffinity: None
  type: NodePort

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
pkg
v1
types
v1

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL