With 0.3, openebs services and the containers (related to OpenEBS volumes) are running in the default namespace. For better abstraction and usability, it will be good to have them under the namespace/openebs.
Following need to be investigated as part of this implementation:
Verify if any further changes are required to the flow for PV (openebs-volume) to connect to the controller via the (service) cluster IP.
I suggest moving this to kube-system namespace. Any pod/deployment thats not application specific and is more likely related to provide low level functionalities ( think of it like the kernel) can go in kibe-system. Ideally for end users, when they have so many namespaces, there is always a risk of non kibe-system namespaces getting purged. Since the openebs once in use are purged by accident would be catastrophic. kube-system comes handy there.
Instead of hardcoding namespace again from default to kube-system, could it be configurable and has some default value? This will cover Miyurz's needs and make space for customization.
Also, current implementation of getMayaClusterIP doesn't work when service defined with externalName and will be great to have name maya-apiserver-service configurable in the openebs-provisioner
OpenEBS provisioner can identify its own namespace and search for maya-apiserver-service in the same namespace. Here, we are reading the namespace of openebs-provisioner from OPENEBS_NAMESPACE env variable. If provisioner is unable to find OPENEBS_NAMESPACE variable then it should set the namespace to default.
To set OPENEBS_NAMESPACE to the namespace.
In openebs-operator.yaml add following:
env:
- name: OPENEBS_NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
PR is merged in kubernetes-incubator & this feature will be available with upcoming release.
Most helpful comment
Instead of hardcoding namespace again from
defaulttokube-system, could it be configurable and has some default value? This will cover Miyurz's needs and make space for customization.Also, current implementation of
getMayaClusterIPdoesn't work when service defined withexternalNameand will be great to have namemaya-apiserver-serviceconfigurable in theopenebs-provisioner