diff --git a/tutor/templates/k8s/deployments.yml b/tutor/templates/k8s/deployments.yml index 1a0bf37..03e27af 100644 --- a/tutor/templates/k8s/deployments.yml +++ b/tutor/templates/k8s/deployments.yml @@ -44,7 +44,7 @@ spec: - name: data persistentVolumeClaim: claimName: cms-data - +{% if ACTIVATE_FORUM %} --- apiVersion: apps/v1 kind: Deployment @@ -71,7 +71,7 @@ spec: value: "http://{{ ELASTICSEARCH_HOST }}:{{ ELASTICSEARCH_PORT }}" - name: MONGOHQ_URL value: "mongodb://{% if MONGODB_USERNAME and MONGODB_PASSWORD %}{{ MONGODB_USERNAME}}:{{ MONGODB_PASSWORD }}@{% endif %}{{ MONGODB_HOST }}:{{ MONGODB_PORT }}/cs_comments_service" - +{% endif %} --- apiVersion: apps/v1 kind: Deployment @@ -115,7 +115,6 @@ spec: - name: data persistentVolumeClaim: claimName: lms-data - {% if ACTIVATE_ELASTICSEARCH %} --- apiVersion: apps/v1 @@ -152,7 +151,6 @@ spec: persistentVolumeClaim: claimName: elasticsearch {% endif %} - {% if ACTIVATE_MEMCACHED %} --- apiVersion: apps/v1 @@ -175,7 +173,6 @@ spec: ports: - containerPort: 11211 {% endif %} - {% if ACTIVATE_MONGODB %} --- apiVersion: apps/v1 @@ -205,7 +202,6 @@ spec: - name: data emptyDir: {} {% endif %} - {% if ACTIVATE_MYSQL %} --- apiVersion: apps/v1 @@ -241,7 +237,6 @@ spec: persistentVolumeClaim: claimName: mysql {% endif %} - {% if ACTIVATE_SMTP %} --- apiVersion: apps/v1 @@ -264,7 +259,6 @@ spec: ports: - containerPort: 25 {% endif %} - --- apiVersion: apps/v1 kind: Deployment @@ -320,7 +314,6 @@ spec: - name: data persistentVolumeClaim: claimName: lms-data - {% if ACTIVATE_RABBITMQ %} --- apiVersion: apps/v1 diff --git a/tutor/templates/k8s/services.yml b/tutor/templates/k8s/services.yml index f582702..bf72156 100644 --- a/tutor/templates/k8s/services.yml +++ b/tutor/templates/k8s/services.yml @@ -10,7 +10,7 @@ spec: protocol: TCP selector: app: cms - +{% if ACTIVATE_FORUM %} --- apiVersion: v1 kind: Service @@ -23,7 +23,7 @@ spec: protocol: TCP selector: app: forum - +{% endif %} --- apiVersion: v1 kind: Service @@ -36,7 +36,6 @@ spec: protocol: TCP selector: app: lms - {% if ACTIVATE_ELASTICSEARCH %} --- apiVersion: v1 @@ -51,7 +50,6 @@ spec: selector: app: elasticsearch {% endif %} - {% if ACTIVATE_MEMCACHED %} --- apiVersion: v1 @@ -66,7 +64,6 @@ spec: selector: app: memcached {% endif %} - {% if ACTIVATE_MONGODB %} --- apiVersion: v1 @@ -81,7 +78,6 @@ spec: selector: app: mongodb {% endif %} - {% if ACTIVATE_MYSQL %} --- apiVersion: v1 @@ -96,7 +92,6 @@ spec: selector: app: mysql {% endif %} - --- apiVersion: v1 kind: Service @@ -115,7 +110,6 @@ spec: targetPort: https-port selector: app: nginx - {% if ACTIVATE_RABBITMQ %} --- apiVersion: v1 @@ -130,7 +124,6 @@ spec: selector: app: rabbitmq {% endif %} - {% if ACTIVATE_SMTP %} --- apiVersion: v1 diff --git a/tutor/templates/k8s/volumes.yml b/tutor/templates/k8s/volumes.yml index e009e8c..c83c093 100644 --- a/tutor/templates/k8s/volumes.yml +++ b/tutor/templates/k8s/volumes.yml @@ -21,7 +21,6 @@ spec: resources: requests: storage: 2Gi - {% if ACTIVATE_ELASTICSEARCH %} --- apiVersion: v1 @@ -35,7 +34,6 @@ spec: requests: storage: 2Gi {% endif %} - {% if ACTIVATE_MYSQL %} --- apiVersion: v1 @@ -49,7 +47,6 @@ spec: requests: storage: 5Gi {% endif %} - --- apiVersion: v1 kind: PersistentVolumeClaim @@ -61,7 +58,6 @@ spec: resources: requests: storage: 1Gi - {% if ACTIVATE_RABBITMQ %} --- apiVersion: v1 @@ -74,4 +70,4 @@ spec: resources: requests: storage: 1Gi -{% endif %} +{% endif %} \ No newline at end of file