summaryrefslogtreecommitdiffstats
path: root/roles/lib_openshift/src/lib/replicationcontroller.py
diff options
context:
space:
mode:
Diffstat (limited to 'roles/lib_openshift/src/lib/replicationcontroller.py')
-rw-r--r--roles/lib_openshift/src/lib/replicationcontroller.py21
1 files changed, 21 insertions, 0 deletions
diff --git a/roles/lib_openshift/src/lib/replicationcontroller.py b/roles/lib_openshift/src/lib/replicationcontroller.py
new file mode 100644
index 000000000..8bcc1e3cc
--- /dev/null
+++ b/roles/lib_openshift/src/lib/replicationcontroller.py
@@ -0,0 +1,21 @@
+# pylint: skip-file
+# flake8: noqa
+
+
+# pylint: disable=too-many-public-methods
+class ReplicationController(DeploymentConfig):
+ ''' Class to model a replicationcontroller openshift object.
+
+ Currently we are modeled after a deployment config since they
+ are very similar. In the future, when the need arises we
+ will add functionality to this class.
+ '''
+ replicas_path = "spec.replicas"
+ env_path = "spec.template.spec.containers[0].env"
+ volumes_path = "spec.template.spec.volumes"
+ container_path = "spec.template.spec.containers"
+ volume_mounts_path = "spec.template.spec.containers[0].volumeMounts"
+
+ def __init__(self, content):
+ ''' Constructor for ReplicationController '''
+ super(ReplicationController, self).__init__(content=content)