2 ## Copyright (C) 2019 Wind River Systems, Inc.
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
16 SUMMARY = "Monitor Helm charts"
17 DESCRIPTION = "Monitor Helm charts"
19 LICENSE = "Apache-2.0"
20 LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
24 monitor-helm-elastic \
29 SRCREV_helm-charts = "92b6289ae93816717a8453cfe62bad51cbdb8ad0"
30 SRCREV_monitor-armada-app = "e5ee6b3a07b74479b93fe90eff0662cf81890f73"
33 git://github.com/helm/charts;protocol=${PROTOCOL};name=helm-charts \
34 git://opendev.org/starlingx/monitor-armada-app.git;protocol=${PROTOCOL};branch=${BRANCH};name=monitor-armada-app;destsuffix=monitor-armada-app \
41 patch_folder = "${WORKDIR}/monitor-armada-app/monitor-helm/files"
42 helm_folder = "${nonarch_libdir}/helm"
43 helmchart_version = "0.1.0"
47 git am ${patch_folder}/0001-Add-Makefile-for-helm-charts.patch
48 git am ${patch_folder}/0002-kibana-workaround-checksum-for-configmap.yaml.patch
49 git am ${patch_folder}/0003-helm-chart-changes-for-stx-monitor.patch
50 git am ${patch_folder}/0004-ipv6-helm-chart-changes.patch
51 git am ${patch_folder}/0005-decouple-config.patch
52 git am ${patch_folder}/0006-add-system-info.patch
53 git am ${patch_folder}/0007-three-masters.patch
54 git am ${patch_folder}/0008-Update-stx-monitor-for-kubernetes-API-1.16.patch
55 git am ${patch_folder}/0009-add-curator-as-of-2019-10-10.patch
56 git am ${patch_folder}/0010-Update-kube-state-metrics-1.8.0-to-commit-09daf19.patch
57 git am ${patch_folder}/0011-update-init-container-env-to-include-node-name.patch
58 git am ${patch_folder}/0012-Add-imagePullSecrets.patch
59 git am ${patch_folder}/0013-removed-unused-images.patch
67 # initialize helm and build the toolkit
68 # helm init --client-only does not work if there is no networking
69 # The following commands do essentially the same as: helm init
70 export HOME="${B}/${USER}"
71 export helm_home="${B}/${USER}/.helm"
75 mkdir ${helm_home}/repository
76 mkdir ${helm_home}/repository/cache
77 mkdir ${helm_home}/repository/local
78 mkdir ${helm_home}/plugins
79 mkdir ${helm_home}/starters
80 mkdir ${helm_home}/cache
81 mkdir ${helm_home}/cache/archive
83 # Stage a repository file that only has a local repo
84 install -m 0644 ${patch_folder}/repositories.yaml ${helm_home}/repository/repositories.yaml
86 # Stage a local repo index that can be updated by the build
87 install -m 0644 ${patch_folder}/index.yaml ${helm_home}/repository/local/index.yaml
89 # Host a server for the charts
90 helm serve --repo-path . &
93 helm repo add local http://localhost:8879/charts
95 # Create the tgz files
99 make kube-state-metrics
103 make elasticsearch-curator
105 # terminate helm server (the last backgrounded task)
111 install -d -m 755 ${D}${helm_folder}
112 install -p -D -m 755 ${S}/stable/*.tgz ${D}${helm_folder}
115 FILES_${PN} = "${helm_folder}"
119 monitor-helm-elastic \