Skip to content

Commit 1b4d673

Browse files
authored
Merge pull request #10 from cdsl-research/future/v2
Fixed k8s deployment config
2 parents 2afa787 + 5a1bb8b commit 1b4d673

File tree

5 files changed

+20
-18
lines changed

5 files changed

+20
-18
lines changed

docs/install_kubernetes.md

+6-2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
You have to read [Common Installation Steps](common.md) before reading this document.
44

5+
```
6+
cd $PROJECT_ROOT/kubernetes
7+
```
8+
59
(1) Create a namespace
610

711
```
@@ -26,5 +30,5 @@ kubectl create configmap hosts-config --from-file=hosts.example.yml
2630
(4) Apply manifests
2731

2832
```
29-
kubectl apply -f ecoman.yml
30-
```
33+
kubectl apply -f .
34+
```

kubernetes/crawler.yml

+4-3
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ spec:
1414
spec:
1515
containers:
1616
- name: crawler-container
17-
image: ghcr.io/cdsl-research/ecoman/crawler:master-9ae0608
17+
image: ghcr.io/cdsl-research/ecoman/crawler:master-2afa787
1818
volumeMounts:
1919
- name: privkey-volume
2020
mountPath: /keys
@@ -23,8 +23,9 @@ spec:
2323
mountPath: /config
2424
readOnly: true
2525
env:
26-
- name: MONGO_USER
27-
value: root
26+
- name: MONGO_USERNAME
27+
value: mongo
28+
# You shoud use SECRET
2829
- name: MONGO_PASSWORD
2930
value: password
3031
- name: MONGO_HOST

kubernetes/dashboard.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ spec:
2222
ports:
2323
- containerPort: 8000
2424
env:
25-
- name: MONGO_USER
26-
value: root
25+
- name: MONGO_USERNAME
26+
value: mongo
27+
# You shoud use SECRET
2728
- name: MONGO_PASSWORD
2829
value: password
2930
- name: MONGO_HOST
@@ -48,5 +49,6 @@ spec:
4849
protocol: "TCP"
4950
port: 8000
5051
targetPort: 8000
52+
nodePort: 32700
5153
selector:
5254
ecoman: dashboard

kubernetes/executor.yml

+1-10
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,6 @@ spec:
2525
ports:
2626
- containerPort: 8000
2727
env:
28-
- name: MONGO_USER
29-
value: mongo
30-
- name: MONGO_PASSWORD
31-
value: password
32-
- name: MONGO_HOST
33-
value: mongo-service
34-
- name: EXECUTOR_ADDRESS
35-
value: executor-service
3628
- name: HOSTS_PATH
3729
value: /config/hosts.yml
3830
volumes:
@@ -50,9 +42,8 @@ spec:
5042
apiVersion: v1
5143
kind: Service
5244
metadata:
53-
name: executor-svc
45+
name: executor-service
5446
spec:
55-
type: NodePort
5647
ports:
5748
- name: "http-port"
5849
protocol: "TCP"

kubernetes/mongodb.yml

+5-1
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,13 @@ spec:
2323
ports:
2424
- containerPort: 27017
2525
env:
26+
- name: MONGO_INITDB_ROOT_USERNAME
27+
value: mongo
28+
# You shoud use SECRET
2629
- name: MONGO_INITDB_ROOT_PASSWORD
2730
value: password
31+
- name: MONGO_INITDB_DATABASE
32+
value: ecoman
2833
volumeMounts:
2934
- name: mongo-volv
3035
mountPath: /data/db
@@ -66,4 +71,3 @@ spec:
6671
port: 27017
6772
targetPort: 27017
6873

69-

0 commit comments

Comments
 (0)