Skip to content

Commit

Permalink
chore: add memory limit & restarts in docker-compose.yml (#13343)
Browse files Browse the repository at this point in the history
  • Loading branch information
fuyufjh authored Nov 10, 2023
1 parent 492076f commit b8b812d
Show file tree
Hide file tree
Showing 3 changed files with 77 additions and 0 deletions.
12 changes: 12 additions & 0 deletions docker/docker-compose-standalone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,13 @@ services:
- bash -c 'printf \"GET / HTTP/1.1\n\n\" > /dev/tcp/127.0.0.1/5690; exit $$?;'
interval: 1s
timeout: 5s
restart: always
deploy:
resources:
limits:
memory: 28Gi
reservations:
memory: 28Gi

etcd-0:
image: "quay.io/coreos/etcd:v3.5.7"
Expand Down Expand Up @@ -120,6 +127,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always

grafana-0:
image: "grafana/grafana-oss:latest"
Expand All @@ -144,6 +152,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always

minio-0:
image: "quay.io/minio/minio:latest"
Expand Down Expand Up @@ -189,6 +198,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always

prometheus-0:
image: "prom/prometheus:latest"
Expand Down Expand Up @@ -216,6 +226,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always

message_queue:
image: "docker.vectorized.io/vectorized/redpanda:latest"
Expand Down Expand Up @@ -255,6 +266,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
volumes:
etcd-0:
external: false
Expand Down
32 changes: 32 additions & 0 deletions docker/docker-compose-with-hdfs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,13 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
deploy:
resources:
limits:
memory: 2Gi
reservations:
memory: 1Gi
compute-node-0:
image: "ghcr.io/risingwavelabs/risingwave:RW_1.1_HADOOP2-x86_64"
command:
Expand Down Expand Up @@ -69,6 +76,13 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
deploy:
resources:
limits:
memory: 26Gi
reservations:
memory: 26Gi
etcd-0:
image: "quay.io/coreos/etcd:v3.5.7"
command:
Expand Down Expand Up @@ -118,6 +132,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
frontend-node-0:
image: "ghcr.io/risingwavelabs/risingwave:RW_1.1_HADOOP2-x86_64"
command:
Expand Down Expand Up @@ -150,6 +165,13 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
deploy:
resources:
limits:
memory: 2Gi
reservations:
memory: 1Gi
grafana-0:
image: "grafana/grafana-oss:latest"
command: []
Expand All @@ -173,6 +195,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
meta-node-0:
image: "ghcr.io/risingwavelabs/risingwave:RW_1.1_HADOOP2-x86_64"
command:
Expand Down Expand Up @@ -219,6 +242,13 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
deploy:
resources:
limits:
memory: 2Gi
reservations:
memory: 1Gi
prometheus-0:
image: "prom/prometheus:latest"
command:
Expand All @@ -245,6 +275,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
connector-node:
image: ghcr.io/risingwavelabs/risingwave:RW_1.1_HADOOP2-x86_64
entrypoint: "/risingwave/bin/connector-node/start-service.sh"
Expand Down Expand Up @@ -290,6 +321,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
volumes:
etcd-0:
external: false
Expand Down
33 changes: 33 additions & 0 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,13 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
deploy:
resources:
limits:
memory: 2Gi
reservations:
memory: 1Gi
compute-node-0:
<<: *image
command:
Expand Down Expand Up @@ -75,6 +82,13 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
deploy:
resources:
limits:
memory: 26Gi
reservations:
memory: 26Gi
etcd-0:
image: "quay.io/coreos/etcd:v3.5.7"
command:
Expand Down Expand Up @@ -123,6 +137,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
frontend-node-0:
<<: *image
command:
Expand Down Expand Up @@ -157,6 +172,13 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
deploy:
resources:
limits:
memory: 2Gi
reservations:
memory: 1Gi
grafana-0:
image: "grafana/grafana-oss:latest"
command: []
Expand All @@ -180,6 +202,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
meta-node-0:
<<: *image
command:
Expand Down Expand Up @@ -227,6 +250,13 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
deploy:
resources:
limits:
memory: 2Gi
reservations:
memory: 1Gi
minio-0:
image: "quay.io/minio/minio:latest"
command:
Expand Down Expand Up @@ -271,6 +301,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
prometheus-0:
image: "prom/prometheus:latest"
command:
Expand All @@ -297,6 +328,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
message_queue:
image: "docker.vectorized.io/vectorized/redpanda:latest"
command:
Expand Down Expand Up @@ -335,6 +367,7 @@ services:
interval: 1s
timeout: 5s
retries: 5
restart: always
volumes:
etcd-0:
external: false
Expand Down

0 comments on commit b8b812d

Please sign in to comment.