diff options
author | Yury Kylulin <yury.kylulin@intel.com> | 2021-11-02 17:47:12 +0300 |
---|---|---|
committer | Yury Kylulin <yury.kylulin@intel.com> | 2021-11-02 18:01:48 +0300 |
commit | b8f652cf6bd2e8b241a02cb2e455086979abbe15 (patch) | |
tree | 0f49bd0816b895e0d8d42e5d5471af4d55bcd6e7 /VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart | |
parent | 75597545ef748d7113591cdbfc8d1aaa88cf15cb (diff) |
Create combined image and add helm chart
Changes in this commit:
1) Create self contained image, rapid scripts can be executed
from the management pod and create other testing pods in the cluster.
2) Helm chart to automate rapid deployment and proper service account
configuration to be able to start management pod.
3) Fix for migration to paramiko.
Signed-off-by: Yury Kylulin <yury.kylulin@intel.com>
Change-Id: I0281871cce392b3003e0274602a5c90c29af9b23
Diffstat (limited to 'VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart')
5 files changed, 99 insertions, 0 deletions
diff --git a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/.helmignore b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/.helmignore new file mode 100644 index 00000000..0e8a0eb3 --- /dev/null +++ b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/.helmignore @@ -0,0 +1,23 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*.orig +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ diff --git a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/Chart.yaml b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/Chart.yaml new file mode 100644 index 00000000..4d210409 --- /dev/null +++ b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/Chart.yaml @@ -0,0 +1,6 @@ +apiVersion: v2 +name: rapid +description: A Helm chart for deploying RAPID test scripts and environment +type: application +version: 0.0.1 +appVersion: "1.0.0" diff --git a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/templates/deployment.yaml b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/templates/deployment.yaml new file mode 100644 index 00000000..74fc6297 --- /dev/null +++ b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/templates/deployment.yaml @@ -0,0 +1,26 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: rapid-testing + namespace: {{ .Values.namespace }} + labels: + app: rapid-testing +spec: + replicas: 1 + selector: + matchLabels: + app: rapid-testing + template: + metadata: + labels: + app: rapid-testing + spec: + serviceAccountName: rapid-testing-sa + containers: + - name: rapid-mgmt + image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + imagePullPolicy: {{ .Values.image.pullPolicy }} + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} diff --git a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/templates/serviceaccount.yaml b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/templates/serviceaccount.yaml new file mode 100644 index 00000000..7886ade3 --- /dev/null +++ b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/templates/serviceaccount.yaml @@ -0,0 +1,36 @@ +--- +apiVersion: v1 +kind: Namespace +metadata: + name: {{ .Values.namespace }} + +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + name: rapid-testing-sa + namespace: {{ .Values.namespace }} + +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: rapid-testing-cr +rules: +- apiGroups: [""] + resources: ["pods", "pods/exec", "pods/status"] + verbs: ["get", "list", "watch", "create", "update", "patch", "delete"] + +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + name: rapid-testing-crb +subjects: +- kind: ServiceAccount + name: rapid-testing-sa + namespace: {{ .Values.namespace }} +roleRef: + kind: ClusterRole + name: rapid-testing-cr + apiGroup: rbac.authorization.k8s.io diff --git a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/values.yaml b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/values.yaml new file mode 100644 index 00000000..76b8037a --- /dev/null +++ b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_helm_chart/values.yaml @@ -0,0 +1,8 @@ +namespace: rapid-testing + +image: + repository: opnfv/rapid + tag: "latest" + pullPolicy: IfNotPresent + +nodeSelector: {} |