Merge pull request #80421 from lostick/fix-es-master-discovery

Fix es initial cluster formation & update es to 7.2.0
This commit is contained in:
Kubernetes Prow Robot 2019-07-25 01:38:06 -07:00 committed by GitHub
commit 10005d2e1e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 20 additions and 15 deletions

View File

@ -17,7 +17,7 @@ COPY elasticsearch_logging_discovery.go go.mod go.sum /
RUN CGO_ENABLED=0 GOOS=linux GO111MODULE=on go build -a -ldflags "-w" -o /elasticsearch_logging_discovery /elasticsearch_logging_discovery.go
FROM docker.elastic.co/elasticsearch/elasticsearch-oss:7.1.1
FROM docker.elastic.co/elasticsearch/elasticsearch-oss:7.2.0
VOLUME ["/data"]
EXPOSE 9200 9300

View File

@ -16,11 +16,12 @@
PREFIX = quay.io/fluentd_elasticsearch
IMAGE = elasticsearch
TAG = v7.1.1
TAG = v7.2.0
build:
docker build --tag ${PREFIX}/${IMAGE}:${TAG} .
docker build --tag ${PREFIX}/${IMAGE}:${TAG} .
docker build --tag ${PREFIX}/${IMAGE}:latest .
push:
docker push ${PREFIX}/${IMAGE}:${TAG}
docker push ${PREFIX}/${IMAGE}:${TAG}
docker push ${PREFIX}/${IMAGE}:latest

View File

@ -4,11 +4,9 @@ node.name: ${NODE_NAME}
node.master: ${NODE_MASTER}
node.data: ${NODE_DATA}
transport.tcp.port: ${TRANSPORT_PORT}
transport.profiles.default.port: ${TRANSPORT_PORT}
http.port: ${HTTP_PORT}
path.data: /data
network.host: 0.0.0.0
discovery.zen.minimum_master_nodes: ${MINIMUM_MASTER_NODES}

View File

@ -124,5 +124,6 @@ func main() {
}
klog.Infof("Endpoints = %s", addrs)
fmt.Printf("discovery.zen.ping.unicast.hosts: [%s]\n", strings.Join(addrs, ", "))
fmt.Printf("discovery.seed_hosts: [%s]\n", strings.Join(addrs, ", "))
fmt.Printf("cluster.initial_master_nodes: [%s]\n", strings.Join(addrs, ", "))
}

View File

@ -23,7 +23,7 @@ require (
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v2 v2.2.2 // indirect
k8s.io/api v0.0.0-20190111032252-67edc246be36 // indirect
k8s.io/api v0.0.0-20190111032252-67edc246be36
k8s.io/apiextensions-apiserver v0.0.0-20190111034747-7d26de67f177 // indirect
k8s.io/apimachinery v0.0.0-20181127025237-2b1284ed4c93
k8s.io/apiserver v0.0.0-20190111033246-d50e9ac5404f // indirect

View File

@ -51,7 +51,7 @@ metadata:
namespace: kube-system
labels:
k8s-app: elasticsearch-logging
version: v7.1.1
version: v7.2.0
addonmanager.kubernetes.io/mode: Reconcile
spec:
serviceName: elasticsearch-logging
@ -59,17 +59,18 @@ spec:
selector:
matchLabels:
k8s-app: elasticsearch-logging
version: v7.1.1
version: v7.2.0
template:
metadata:
labels:
k8s-app: elasticsearch-logging
version: v7.1.1
version: v7.2.0
spec:
serviceAccountName: elasticsearch-logging
containers:
- image: quay.io/fluentd_elasticsearch/elasticsearch:v7.1.1
- image: quay.io/fluentd_elasticsearch/elasticsearch:v7.2.0
name: elasticsearch-logging
imagePullPolicy: Always
resources:
# need more cpu upon initialization, therefore burstable class
limits:

View File

@ -20,7 +20,7 @@ spec:
spec:
containers:
- name: kibana-logging
image: docker.elastic.co/kibana/kibana-oss:7.1.1
image: docker.elastic.co/kibana/kibana-oss:7.2.0
resources:
# need more cpu upon initialization, therefore burstable class
limits:
@ -28,10 +28,14 @@ spec:
requests:
cpu: 100m
env:
- name: ELASTICSEARCH_URL
- name: ELASTICSEARCH_HOSTS
value: http://elasticsearch-logging:9200
- name: SERVER_NAME
value: kibana-logging
- name: SERVER_BASEPATH
value: /api/v1/namespaces/kube-system/services/kibana-logging/proxy
- name: SERVER_REWRITEBASEPATH
value: "false"
ports:
- containerPort: 5601
name: ui