Skip to content

Commit

Permalink
Adding manifests for v2.3.0 ChaosCenter (#3335)
Browse files Browse the repository at this point in the history
* Adding manifests for v2.3.0 ChaosCenter

Signed-off-by: Jonsy13 <[email protected]>

* Adding manifests for v2.3.0 ChaosCenter

Signed-off-by: Jonsy13 <[email protected]>

* Added initContainer for version upgrade.

Signed-off-by: Jonsy13 <[email protected]>

* Added initContainer for version upgrade.

Signed-off-by: Jonsy13 <[email protected]>
  • Loading branch information
Jonsy13 authored Nov 15, 2021
1 parent a0fa142 commit 22f11d2
Show file tree
Hide file tree
Showing 6 changed files with 1,522 additions and 3 deletions.
6 changes: 3 additions & 3 deletions litmus-portal/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ Litmus-Portal provides console and UI experience for managing, monitoring, and e

#### Applying k8s manifest

> Litmus-2.2.0 (Stable)
> Litmus-2.3.0 (Stable)
```bash
kubectl apply -f https://raw.githubusercontent.com/litmuschaos/litmus/2.2.0/mkdocs/docs/2.2.0/litmus-2.2.0.yaml
kubectl apply -f https://raw.githubusercontent.com/litmuschaos/litmus/2.3.0/mkdocs/docs/2.3.0/litmus-2.3.0.yaml
```

Or
Expand All @@ -44,7 +44,7 @@ Or
export LITMUS_PORTAL_NAMESPACE="<namespace>"
kubectl create ns ${LITMUS_PORTAL_NAMESPACE}
kubectl apply -f https://raw.githubusercontent.com/litmuschaos/litmus/master/litmus-portal/litmus-portal-crds.yml
curl https://raw.githubusercontent.com/litmuschaos/litmus/2.2.0/mkdocs/docs/2.2.0/litmus-namespaced-2.2.0.yaml --output litmus-portal-namespaced-k8s-template.yml
curl https://raw.githubusercontent.com/litmuschaos/litmus/2.3.0/mkdocs/docs/2.3.0/litmus-namespaced-2.3.0.yaml --output litmus-portal-namespaced-k8s-template.yml
envsubst '${LITMUS_PORTAL_NAMESPACE}' < litmus-portal-namespaced-k8s-template.yml > ${LITMUS_PORTAL_NAMESPACE}-ns-scoped-litmus-portal-manifest.yml
kubectl apply -f ${LITMUS_PORTAL_NAMESPACE}-ns-scoped-litmus-portal-manifest.yml -n ${LITMUS_PORTAL_NAMESPACE}
```
Expand Down
25 changes: 25 additions & 0 deletions litmus-portal/cluster-k8s-manifest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -563,6 +563,31 @@ spec:
[
"while [[ $(curl -sw '%{http_code}' http://mongo-service:27017 -o /dev/null) -ne 200 ]]; do sleep 5; echo 'Waiting for the MongoDB to be ready...'; done; echo 'Connection with MongoDB established'",
]
- name: server-version-updater
image: litmuschaos/mongo-utils:latest
command: ["/bin/sh"]
args: ["-c"," mongo $DB_SERVER --username $DB_USER --password $DB_PASSWORD --eval 'db=db.getSiblingDB(\"litmus\");db.getCollection(\"server-config-collection\").updateOne({\"key\":\"version\"},{ \"$set\":{ \"value\":\"'$VERSION'\"}})'"]
env:
- name: VERSION
valueFrom:
configMapKeyRef:
name: litmus-portal-admin-config
key: VERSION
- name: DB_USER
valueFrom:
secretKeyRef:
name: litmus-portal-admin-secret
key: DB_USER
- name: DB_PASSWORD
valueFrom:
secretKeyRef:
name: litmus-portal-admin-secret
key: DB_PASSWORD
- name: DB_SERVER
valueFrom:
configMapKeyRef:
name: litmus-portal-admin-config
key: DB_SERVER
containers:
- name: graphql-server
image: litmuschaos/litmusportal-server:ci
Expand Down
25 changes: 25 additions & 0 deletions litmus-portal/namespaced-k8s-template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -544,6 +544,31 @@ spec:
[
"while [[ $(curl -sw '%{http_code}' http://mongo-service:27017 -o /dev/null) -ne 200 ]]; do sleep 5; echo 'Waiting for the MongoDB to be ready...'; done; echo 'Connection with MongoDB established'",
]
- name: server-version-updater
image: litmuschaos/mongo-utils:latest
command: ["/bin/sh"]
args: ["-c"," mongo $DB_SERVER --username $DB_USER --password $DB_PASSWORD --eval 'db=db.getSiblingDB(\"litmus\");db.getCollection(\"server-config-collection\").updateOne({\"key\":\"version\"},{ \"$set\":{ \"value\":\"'$VERSION'\"}})'"]
env:
- name: VERSION
valueFrom:
configMapKeyRef:
name: litmus-portal-admin-config
key: VERSION
- name: DB_USER
valueFrom:
secretKeyRef:
name: litmus-portal-admin-secret
key: DB_USER
- name: DB_PASSWORD
valueFrom:
secretKeyRef:
name: litmus-portal-admin-secret
key: DB_PASSWORD
- name: DB_SERVER
valueFrom:
configMapKeyRef:
name: litmus-portal-admin-config
key: DB_SERVER
containers:
- name: graphql-server
image: litmuschaos/litmusportal-server:ci
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -548,6 +548,31 @@ spec:
[
"while [[ $(curl -sw '%{http_code}' http://mongo-service:27017 -o /dev/null) -ne 200 ]]; do sleep 5; echo 'Waiting for the MongoDB to be ready...'; done; echo 'Connection with MongoDB established'",
]
- name: server-version-updater
image: litmuschaos/mongo-utils:latest
command: ["/bin/sh"]
args: ["-c"," mongo $DB_SERVER --username $DB_USER --password $DB_PASSWORD --eval 'db=db.getSiblingDB(\"litmus\");db.getCollection(\"server-config-collection\").updateOne({\"key\":\"version\"},{ \"$set\":{ \"value\":\"'$VERSION'\"}})'"]
env:
- name: VERSION
valueFrom:
configMapKeyRef:
name: litmus-portal-admin-config
key: VERSION
- name: DB_USER
valueFrom:
secretKeyRef:
name: litmus-portal-admin-secret
key: DB_USER
- name: DB_PASSWORD
valueFrom:
secretKeyRef:
name: litmus-portal-admin-secret
key: DB_PASSWORD
- name: DB_SERVER
valueFrom:
configMapKeyRef:
name: litmus-portal-admin-config
key: DB_SERVER
containers:
- name: graphql-server
image: litmuschaos/litmusportal-server:ci
Expand Down
Loading

0 comments on commit 22f11d2

Please sign in to comment.