mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-02 00:07:50 +00:00
Store logs from etcd in kubemark
This commit is contained in:
parent
52498e6050
commit
752f414905
@ -29,21 +29,23 @@ retry() {
|
|||||||
|
|
||||||
if [ "${EVENT_STORE_IP}" == "127.0.0.1" ]; then
|
if [ "${EVENT_STORE_IP}" == "127.0.0.1" ]; then
|
||||||
# Retry starting etcd to avoid pulling image errors.
|
# Retry starting etcd to avoid pulling image errors.
|
||||||
retry sudo docker run --net=host -v /var/etcd/data-events:/var/etcd/data -d \
|
retry sudo docker run --net=host \
|
||||||
gcr.io/google_containers/etcd:3.0.4 /usr/local/bin/etcd \
|
-v /var/etcd/data-events:/var/etcd/data -v /var/log:/var/log -d \
|
||||||
|
gcr.io/google_containers/etcd:3.0.4 /bin/sh -c "/usr/local/bin/etcd \
|
||||||
--listen-peer-urls http://127.0.0.1:2381 \
|
--listen-peer-urls http://127.0.0.1:2381 \
|
||||||
--advertise-client-urls=http://127.0.0.1:4002 \
|
--advertise-client-urls=http://127.0.0.1:4002 \
|
||||||
--listen-client-urls=http://0.0.0.0:4002 \
|
--listen-client-urls=http://0.0.0.0:4002 \
|
||||||
--data-dir=/var/etcd/data
|
--data-dir=/var/etcd/data 1>> /var/log/etcd-events.log 2>&1"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Retry starting etcd to avoid pulling image errors.
|
# Retry starting etcd to avoid pulling image errors.
|
||||||
retry sudo docker run --net=host -v /var/etcd/data:/var/etcd/data -d \
|
retry sudo docker run --net=host \
|
||||||
gcr.io/google_containers/etcd:3.0.4 /usr/local/bin/etcd \
|
-v /var/etcd/data:/var/etcd/data -v /var/log:/var/log -d \
|
||||||
|
gcr.io/google_containers/etcd:3.0.4 /bin/sh -c "/usr/local/bin/etcd \
|
||||||
--listen-peer-urls http://127.0.0.1:2380 \
|
--listen-peer-urls http://127.0.0.1:2380 \
|
||||||
--advertise-client-urls=http://127.0.0.1:2379 \
|
--advertise-client-urls=http://127.0.0.1:2379 \
|
||||||
--listen-client-urls=http://0.0.0.0:2379 \
|
--listen-client-urls=http://0.0.0.0:2379 \
|
||||||
--data-dir=/var/etcd/data
|
--data-dir=/var/etcd/data 1>> /var/log/etcd.log 2>&1"
|
||||||
|
|
||||||
# Increase the allowed number of open file descriptors
|
# Increase the allowed number of open file descriptors
|
||||||
ulimit -n 65536
|
ulimit -n 65536
|
||||||
|
Loading…
Reference in New Issue
Block a user