You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by ke...@apache.org on 2020/10/16 16:31:51 UTC
[skywalking-kubernetes] branch refactor updated (9f5473b -> 5edebe1)
This is an automated email from the ASF dual-hosted git repository.
kezhenxu94 pushed a change to branch refactor
in repository https://gitbox.apache.org/repos/asf/skywalking-kubernetes.git.
discard 9f5473b Refactor to unify the versions of SkyWalking
new 5edebe1 Refactor to unify the versions of SkyWalking
This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version. This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:
* -- * -- B -- O -- O -- O (9f5473b)
\
N -- N -- N refs/heads/refactor (5edebe1)
You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.
Any revisions marked "omit" are not gone; other references still
refer to them. Any revisions marked "discard" are gone forever.
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
chart/skywalking/README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[skywalking-kubernetes] 01/01: Refactor to unify the versions of
SkyWalking
Posted by ke...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
kezhenxu94 pushed a commit to branch refactor
in repository https://gitbox.apache.org/repos/asf/skywalking-kubernetes.git
commit 5edebe113c89d4c2bc758829d4745017834e6bf5
Author: kezhenxu94 <ke...@163.com>
AuthorDate: Sat Oct 17 00:20:04 2020 +0800
Refactor to unify the versions of SkyWalking
---
.gitignore | 1 +
README.md | 97 ++++++----
chart/skywalking/README.md | 4 +-
chart/skywalking/values-es6.yaml | 356 -------------------------------------
chart/skywalking/values-es7.yaml | 26 +++
chart/skywalking/values-my-es.yaml | 27 +++
chart/skywalking/values.yaml | 8 +-
7 files changed, 121 insertions(+), 398 deletions(-)
diff --git a/.gitignore b/.gitignore
index 538c8c5..495004e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,3 @@
.DS_Store
*~
+.idea
diff --git a/README.md b/README.md
index 1fe724e..2c9c52b 100644
--- a/README.md
+++ b/README.md
@@ -6,66 +6,91 @@ Apache SkyWalking Kubernetes
[](https://github.com/apache/skywalking)
[](https://twitter.com/AsfSkyWalking)
-SkyWalking Kubernetes repository provides ways to install and configure skywalking in a Kubernetes cluster.
-The scripts are written in Helm3.
+SkyWalking Kubernetes repository provides ways to install and configure SkyWalking in a Kubernetes cluster.
+The scripts are written in Helm 3.
## Documentation
-#### Chart Detailed Configuration
-chart detailed configuration please read [Chart Readme](./chart/skywalking/README.md)
+### Chart Detailed Configuration
+Chart detailed configuration can be found at [Chart Readme](./chart/skywalking/README.md)
-#### Deploy SkyWalking and Elasticsearch 7 (default)
+### Deploy SkyWalking in a Kubernetes cluster
-```shell script
-$ cd chart
+#### Prerequisites
-$ helm repo add elastic https://helm.elastic.co
+```shell script
+git clone https://github.com/apache/skywalking-kubernetes
+cd skywalking-kubernetes/chart
+helm repo add elastic https://helm.elastic.co
+helm dep up skywalking
+export SKYWALKING_RELEASE_NAME=skywalking # change the release name according to your scenario
+export SKYWALKING_RELEASE_NAMESPACE=istio-system # change the namespace according to your scenario
+```
-$ helm dep up skywalking
+#### Deploy the latest SkyWalking & Elasticsearch 6 (default)
-$ helm install <release_name> skywalking -n <namespace>
+```shell script
+helm install "${SKYWALKING_RELEASE_NAME}" skywalking -n "${SKYWALKING_RELEASE_NAMESPACE}"
```
-**Note**: If you want to deploy Elasticsearch 6, execute the following command
+#### Deploy the latest SkyWalking & Elasticsearch 7
```shell script
-$ helm dep up skywalking
-
-$ helm install <release_name> skywalking -n <namespace> --values ./skywalking/values-es6.yaml
+helm install "${SKYWALKING_RELEASE_NAME}" skywalking -n "${SKYWALKING_RELEASE_NAMESPACE}" \
+ -f ./skywalking/values.yaml \
+ -f ./skywalking/values-es7.yaml
```
-#### Only deploy SkyWalking ,and use existing Elasticsearch
-If not want to deploy a new elasticsearch cluster, this way can be solved.
+#### Deploy a specific version of SkyWalking & Elasticsearch
+
+- Deploy SkyWalking 8.0.1 & Elasticsearch 6.8.6
-Only need to close the elasticsearch deployed by chart default and configure the existing elasticsearch connection method.
+```shell script
+helm install "${SKYWALKING_RELEASE_NAME}" skywalking -n "${SKYWALKING_RELEASE_NAMESPACE}" \
+ --set oap.image.tag=8.0.1-es6 \
+ --set ui.image.tag=8.0.1 \
+ --set elasticsearch.imageTag=6.8.6
+```
+- Deploy SkyWalking 8.1.0 & Elasticsearch 7.5.1
```shell script
-$ cd chart
+helm install "${SKYWALKING_RELEASE_NAME}" skywalking -n "${SKYWALKING_RELEASE_NAMESPACE}" \
+ --set oap.image.tag=8.1.0-es7 \
+ --set ui.image.tag=8.1.0 \
+ --set elasticsearch.imageTag=7.5.1
+```
-$ helm repo add elastic https://helm.elastic.co
+**NOTE**: Please make sure the specified OAP image tag supports the specified Elasticsearch version.
-$ helm dep up skywalking
+#### Deploy the latest SkyWalking & an existing Elasticsearch
-$ helm install <release_name> skywalking -n <namespace> \
- --set elasticsearch.enabled=false \
- --set elasticsearch.config.host=<es_host> \
- --set elasticsearch.config.port.http=<es_port> \
- --set elasticsearch.config.user=<es_user> \
- --set elasticsearch.config.password=<es_password>
+1. Modify the connection information to the existing elasticsearch cluster in file [`values-my-es.yaml`](chart/skywalking/values-my-es.yaml).
+1. Execute the command.
+```shell script
+helm install "${SKYWALKING_RELEASE_NAME}" skywalking -n "${SKYWALKING_RELEASE_NAMESPACE}" \
+ -f ./skywalking/values.yaml \
+ -f ./skywalking/values-my-es.yaml
+```
+
+OR, if your existing Elasticsearch version is 7.x.x
+
+```shell script
+helm install "${SKYWALKING_RELEASE_NAME}" skywalking -n "${SKYWALKING_RELEASE_NAMESPACE}" \
+ -f ./skywalking/values.yaml \
+ -f ./skywalking/values-es7.yaml \
+ -f ./skywalking/values-my-es.yaml
```
-**Note**: You need to make sure your ES cluster version is 7.x , If your cluster version is 6.x, execute the following command
+You can also add `--set oap.image.tag=<oap.tag> --set ui.image.tag=<ui.tag>` to deploy a specific version of SkyWalking with
+the existing Elasticsearch, as [mentioned above](#deploy-a-specific-version-of-skywalking--elasticsearch), for example:
```shell script
-$ helm dep up skywalking
-
-$ helm install <release_name> skywalking -n <namespace> \
- --values ./skywalking/values-es6.yaml \
- --set elasticsearch.enabled=false \
- --set elasticsearch.config.host=<es_host> \
- --set elasticsearch.config.port.http=<es_port> \
- --set elasticsearch.config.user=<es_user> \
- --set elasticsearch.config.password=<es_password>
+helm install "${SKYWALKING_RELEASE_NAME}" skywalking -n "${SKYWALKING_RELEASE_NAMESPACE}" \
+ -f ./skywalking/values.yaml \
+ -f ./skywalking/values-es7.yaml \
+ -f ./skywalking/values-my-es.yaml \
+ --set oap.image.tag=8.1.0-es7 \
+ --set ui.image.tag=8.1.0
```
## Structure of repository
diff --git a/chart/skywalking/README.md b/chart/skywalking/README.md
index d4b2c87..2059001 100644
--- a/chart/skywalking/README.md
+++ b/chart/skywalking/README.md
@@ -151,7 +151,7 @@ Alternatively, a YAML file that specifies the values for the above parameters ca
$ helm install my-release skywalking -f values.yaml
```
-> **Tip**: You can use the default [values.yaml](values.yaml)
+> **Tip**: You can use the default [values.yaml](./values.yaml)
### RBAC Configuration
Roles and RoleBindings resources will be created automatically for `OAP` .
@@ -204,4 +204,4 @@ oap:
```
When envoy als ,will give ServiceAccount clusterrole permission.
-More envoy als ,please refer to https://github.com/apache/skywalking/blob/master/docs/en/setup/envoy/als_setting.md#observe-service-mesh-through-als
\ No newline at end of file
+More envoy als ,please refer to https://github.com/apache/skywalking/blob/master/docs/en/setup/envoy/als_setting.md#observe-service-mesh-through-als
diff --git a/chart/skywalking/values-es6.yaml b/chart/skywalking/values-es6.yaml
deleted file mode 100644
index 0a46fc7..0000000
--- a/chart/skywalking/values-es6.yaml
+++ /dev/null
@@ -1,356 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Default values for skywalking.
-# This is a YAML-formatted file.
-# Declare variables to be passed into your templates.
-
-serviceAccounts:
- oap:
-
-oap:
- name: oap
- # When 'dynamicConfigEnabled' set to true, enable oap dynamic configuration through k8s configmap,
- # Note: The default configmap data is empty, please refer to the detailed documentation (https://github.com/apache/skywalking/blob/master/docs/en/setup/backend/dynamic-config.md)
- # Sync period in seconds. Defaults to 60 seconds. env: SW_CONFIG_CONFIGMAP_PERIOD
- dynamicConfigEnabled: false
- image:
- repository: apache/skywalking-oap-server
- tag: 8.1.0-es6
- pullPolicy: IfNotPresent
- storageType: elasticsearch
- ports:
- grpc: 11800
- rest: 12800
- replicas: 2
- service:
- type: ClusterIP
- javaOpts: -Xmx2g -Xms2g
- antiAffinity: "soft"
- nodeAffinity: {}
- nodeSelector: {}
- tolerations: []
- resources: {}
- # limits:
- # cpu: 8
- # memory: 8Gi
- # requests:
- # cpu: 8
- # memory: 4Gi
- # podAnnotations:
- # example: oap-foo
- envoy:
- als:
- enabled: false
- # more envoy ALS ,please refer to https://github.com/apache/skywalking/blob/master/docs/en/setup/envoy/als_setting.md#observe-service-mesh-through-als
- istio:
- adapter:
- enabled: false
- env:
- # more env, please refer to https://hub.docker.com/r/apache/skywalking-oap-server
- # or https://github.com/apache/skywalking-docker/blob/master/6/6.4/oap/README.md#sw_telemetry
-ui:
- name: ui
- replicas: 1
- image:
- repository: apache/skywalking-ui
- tag: 8.1.0
- pullPolicy: IfNotPresent
- # podAnnotations:
- # example: oap-foo
- ingress:
- enabled: false
- annotations: {}
- # kubernetes.io/ingress.class: nginx
- # kubernetes.io/tls-acme: "true"
- path: /
- hosts: []
- # - skywalking.local
- tls: []
- # - secretName: skywalking-tls
- # hosts:
- # - skywalking.local
- service:
- type: ClusterIP
- # clusterIP: None
- externalPort: 80
- internalPort: 8080
- ## External IP addresses of service
- ## Default: nil
- ##
- # externalIPs:
- # - 192.168.0.1
- #
- ## LoadBalancer IP if service.type is LoadBalancer
- ## Default: nil
- ##
- # loadBalancerIP: 10.2.2.2
- # Annotation example: setup ssl with aws cert when service.type is LoadBalancer
- # service.beta.kubernetes.io/aws-load-balancer-ssl-cert: arn:aws:acm:us-east-1:EXAMPLE_CERT
- annotations: {}
- ## Limit load balancer source ips to list of CIDRs (where available)
- # loadBalancerSourceRanges: []
-
-elasticsearch:
- enabled: true
- config: # For users of an existing elasticsearch cluster,takes effect when `elasticsearch.enabled` is false
- port:
- http: 9200
- host: elasticsearch # es service on kubernetes or host
- user: "xxx" # [optional]
- password: "xxx" # [optional]
- clusterName: "elasticsearch"
- nodeGroup: "master"
-
- # The service that non master groups will try to connect to when joining the cluster
- # This should be set to clusterName + "-" + nodeGroup for your master group
- masterService: ""
-
- # Elasticsearch roles that will be applied to this nodeGroup
- # These will be set as environment variables. E.g. node.master=true
- roles:
- master: "true"
- ingest: "true"
- data: "true"
-
- replicas: 3
- minimumMasterNodes: 2
-
- esMajorVersion: ""
-
- # Allows you to add any config files in /usr/share/elasticsearch/config/
- # such as elasticsearch.yml and log4j2.properties
- esConfig: {}
- # elasticsearch.yml: |
- # key:
- # nestedkey: value
- # log4j2.properties: |
- # key = value
-
- # Extra environment variables to append to this nodeGroup
- # This will be appended to the current 'env:' key. You can use any of the kubernetes env
- # syntax here
- extraEnvs: []
- # - name: MY_ENVIRONMENT_VAR
- # value: the_value_goes_here
-
- # A list of secrets and their paths to mount inside the pod
- # This is useful for mounting certificates for security and for mounting
- # the X-Pack license
- secretMounts: []
- # - name: elastic-certificates
- # secretName: elastic-certificates
- # path: /usr/share/elasticsearch/config/certs
-
- image: "docker.elastic.co/elasticsearch/elasticsearch"
- imageTag: "6.8.6"
- imagePullPolicy: "IfNotPresent"
-
- podAnnotations: {}
- # iam.amazonaws.com/role: es-cluster
-
- # additionals labels
- labels: {}
-
- esJavaOpts: "-Xmx1g -Xms1g"
-
- resources:
- requests:
- cpu: "100m"
- memory: "2Gi"
- limits:
- cpu: "1000m"
- memory: "2Gi"
-
- initResources: {}
- # limits:
- # cpu: "25m"
- # # memory: "128Mi"
- # requests:
- # cpu: "25m"
- # memory: "128Mi"
-
- sidecarResources: {}
- # limits:
- # cpu: "25m"
- # # memory: "128Mi"
- # requests:
- # cpu: "25m"
- # memory: "128Mi"
-
- networkHost: "0.0.0.0"
-
- volumeClaimTemplate:
- accessModes: [ "ReadWriteOnce" ]
- resources:
- requests:
- storage: 30Gi
-
- rbac:
- create: false
- serviceAccountName: ""
-
- podSecurityPolicy:
- create: false
- name: ""
- spec:
- privileged: true
- fsGroup:
- rule: RunAsAny
- runAsUser:
- rule: RunAsAny
- seLinux:
- rule: RunAsAny
- supplementalGroups:
- rule: RunAsAny
- volumes:
- - secret
- - configMap
- - persistentVolumeClaim
-
- persistence:
- enabled: false
- annotations: {}
-
- extraVolumes: ""
- # - name: extras
- # emptyDir: {}
-
- extraVolumeMounts: ""
- # - name: extras
- # mountPath: /usr/share/extras
- # readOnly: true
-
- extraInitContainers: ""
- # - name: do-something
- # image: busybox
- # command: ['do', 'something']
-
- # This is the PriorityClass settings as defined in
- # https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/#priorityclass
- priorityClassName: ""
-
- # By default this will make sure two pods don't end up on the same node
- # Changing this to a region would allow you to spread pods across regions
- antiAffinityTopologyKey: "kubernetes.io/hostname"
-
- # Hard means that by default pods will only be scheduled if there are enough nodes for them
- # and that they will never end up on the same node. Setting this to soft will do this "best effort"
- antiAffinity: "hard"
-
- # This is the node affinity settings as defined in
- # https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#node-affinity-beta-feature
- nodeAffinity: {}
-
- # The default is to deploy all pods serially. By setting this to parallel all pods are started at
- # the same time when bootstrapping the cluster
- podManagementPolicy: "Parallel"
-
- protocol: http
- httpPort: 9200
- transportPort: 9300
-
- service:
- labels: {}
- labelsHeadless: {}
- type: ClusterIP
- nodePort: ""
- annotations: {}
- httpPortName: http
- transportPortName: transport
-
- updateStrategy: RollingUpdate
-
- # This is the max unavailable setting for the pod disruption budget
- # The default value of 1 will make sure that kubernetes won't allow more than 1
- # of your pods to be unavailable during maintenance
- maxUnavailable: 1
-
- podSecurityContext:
- fsGroup: 1000
- runAsUser: 1000
-
- # The following value is deprecated,
- # please use the above podSecurityContext.fsGroup instead
- fsGroup: ""
-
- securityContext:
- capabilities:
- drop:
- - ALL
- # readOnlyRootFilesystem: true
- runAsNonRoot: true
- runAsUser: 1000
-
- # How long to wait for elasticsearch to stop gracefully
- terminationGracePeriod: 120
-
- sysctlVmMaxMapCount: 262144
-
- readinessProbe:
- failureThreshold: 3
- initialDelaySeconds: 10
- periodSeconds: 10
- successThreshold: 3
- timeoutSeconds: 5
-
- # https://www.elastic.co/guide/en/elasticsearch/reference/current/cluster-health.html#request-params wait_for_status
- clusterHealthCheckParams: "wait_for_status=green&timeout=1s"
-
- ## Use an alternate scheduler.
- ## ref: https://kubernetes.io/docs/tasks/administer-cluster/configure-multiple-schedulers/
- ##
- schedulerName: ""
-
- imagePullSecrets: []
- nodeSelector: {}
- tolerations: []
-
- # Enabling this will publically expose your Elasticsearch instance.
- # Only enable this if you have security enabled on your cluster
- ingress:
- enabled: false
- annotations: {}
- # kubernetes.io/ingress.class: nginx
- # kubernetes.io/tls-acme: "true"
- path: /
- hosts:
- - chart-example.local
- tls: []
- # - secretName: chart-example-tls
- # hosts:
- # - chart-example.local
-
- nameOverride: ""
- fullnameOverride: ""
-
- # https://github.com/elastic/helm-charts/issues/63
- masterTerminationFix: false
-
- lifecycle: {}
- # preStop:
- # exec:
- # command: ["/bin/sh", "-c", "echo Hello from the postStart handler > /usr/share/message"]
- # postStart:
- # exec:
- # command: ["/bin/sh", "-c", "echo Hello from the postStart handler > /usr/share/message"]
-
- sysctlInitContainer:
- enabled: true
-
- keystore: []
-
-nameOverride: ""
-fullnameOverride: ""
\ No newline at end of file
diff --git a/chart/skywalking/values-es7.yaml b/chart/skywalking/values-es7.yaml
new file mode 100644
index 0000000..7835184
--- /dev/null
+++ b/chart/skywalking/values-es7.yaml
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Default values for skywalking.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+
+oap:
+ image:
+ tag: 8.1.0-es7 # TODO: give a tag "latest-es7"
+ storageType: elasticsearch7
+
+elasticsearch:
+ imageTag: "7.5.1"
diff --git a/chart/skywalking/values-my-es.yaml b/chart/skywalking/values-my-es.yaml
new file mode 100644
index 0000000..dbec45f
--- /dev/null
+++ b/chart/skywalking/values-my-es.yaml
@@ -0,0 +1,27 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Default values for skywalking.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+
+elasticsearch:
+ enabled: false
+ config: # For users of an existing elasticsearch cluster,takes effect when `elasticsearch.enabled` is false
+ host: your.elasticsearch.host.or.ip
+ port:
+ http: 9200
+ user: "xxx" # [optional]
+ password: "xxx" # [optional]
diff --git a/chart/skywalking/values.yaml b/chart/skywalking/values.yaml
index dd4c1a0..fbe77bd 100644
--- a/chart/skywalking/values.yaml
+++ b/chart/skywalking/values.yaml
@@ -30,9 +30,9 @@ oap:
dynamicConfigEnabled: false
image:
repository: apache/skywalking-oap-server
- tag: 8.1.0-es7
+ tag: latest
pullPolicy: IfNotPresent
- storageType: elasticsearch7
+ storageType: elasticsearch
ports:
grpc: 11800
rest: 12800
@@ -157,7 +157,7 @@ elasticsearch:
# path: /usr/share/elasticsearch/config/certs
image: "docker.elastic.co/elasticsearch/elasticsearch"
- imageTag: "7.5.1"
+ imageTag: "6.8.6"
imagePullPolicy: "IfNotPresent"
podAnnotations: {}
@@ -355,4 +355,4 @@ elasticsearch:
keystore: []
nameOverride: ""
-fullnameOverride: ""
\ No newline at end of file
+fullnameOverride: ""