Merge remote-tracking branch 'origin/develop' into nr-dl-mimo-2layer
This commit is contained in:
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-physim
|
||||||
|
description: A Helm chart for physical simulators network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulators
|
||||||
|
- RAN
|
||||||
|
- 4G
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-dlsim
|
||||||
|
description: A Helm subchart for dlsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- dlsim
|
||||||
|
- RAN
|
||||||
|
- 4G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-dlsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-dlsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-dlsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-dlsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-dlsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-dlsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-dlsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-dlsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-dlsim.chart" . }}
|
||||||
|
{{ include "oai-dlsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-dlsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-dlsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-dlsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-dlsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-dlsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-dlsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-dlsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-dlsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-dlsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015100" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-dlsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-dlsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-dlsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-dlsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-dlsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-ldpctest
|
||||||
|
description: A Helm subchart for ldpctest network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- ldpctest
|
||||||
|
- RAN
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-ldpctest.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-ldpctest.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-ldpctest.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-ldpctest.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ldpctest.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ldpctest.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ldpctest.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ldpctest.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-ldpctest.chart" . }}
|
||||||
|
{{ include "oai-ldpctest.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ldpctest.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-ldpctest.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ldpctest.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-ldpctest.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-ldpctest.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-ldpctest.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-ldpctest.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-ldpctest
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-ldpctest/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015102" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-ldpctest.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-ldpctest
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-ldpctest.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-ldpctest.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-ldpctest-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-nr-dlschsim
|
||||||
|
description: A Helm subchart for nr-dlschsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- nr-dlschsim
|
||||||
|
- RAN
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-nr-dlschsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-nr-dlschsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-nr-dlschsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-nr-dlschsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlschsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlschsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlschsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlschsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-nr-dlschsim.chart" . }}
|
||||||
|
{{ include "oai-nr-dlschsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlschsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-nr-dlschsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlschsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-nr-dlschsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-dlschsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-nr-dlschsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-dlschsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-nr-dlschsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-nr-dlschsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015106" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-dlschsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-nr-dlschsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-nr-dlschsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-nr-dlschsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-nr-dlschsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-nr-dlsim
|
||||||
|
description: A Helm subchart for nr-dlsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- nr-dlsim
|
||||||
|
- RAN
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-nr-dlsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-nr-dlsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-nr-dlsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-nr-dlsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-nr-dlsim.chart" . }}
|
||||||
|
{{ include "oai-nr-dlsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-nr-dlsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-dlsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-nr-dlsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-dlsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-nr-dlsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-dlsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-nr-dlsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-nr-dlsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015105" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-dlsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-nr-dlsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-nr-dlsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-nr-dlsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-nr-dlsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-nr-pbchsim
|
||||||
|
description: A Helm subchart for nr-pbchsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- nr-pbchsim
|
||||||
|
- RAN
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-nr-pbchsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-nr-pbchsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-nr-pbchsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-nr-pbchsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pbchsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pbchsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pbchsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pbchsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-nr-pbchsim.chart" . }}
|
||||||
|
{{ include "oai-nr-pbchsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pbchsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-nr-pbchsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pbchsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-nr-pbchsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-pbchsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-nr-pbchsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-pbchsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-nr-pbchsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-nr-pbchsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015104" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-pbchsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-nr-pbchsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-nr-pbchsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-nr-pbchsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-nr-pbchsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-nr-prachsim
|
||||||
|
description: A Helm subchart for nr-prachsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- nr-prachsim
|
||||||
|
- RAN
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-nr-prachsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-nr-prachsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-nr-prachsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-nr-prachsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-prachsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-prachsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-prachsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-prachsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-nr-prachsim.chart" . }}
|
||||||
|
{{ include "oai-nr-prachsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-prachsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-nr-prachsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-prachsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-nr-prachsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-prachsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-nr-prachsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-prachsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-nr-prachsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-nr-prachsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015112" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-prachsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-nr-prachsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-nr-prachsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-nr-prachsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-nr-prachsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-nr-pucchsim
|
||||||
|
description: A Helm subchart for nr-pucchsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- nr-pucchsim
|
||||||
|
- RAN
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-nr-pucchsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-nr-pucchsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-nr-pucchsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-nr-pucchsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pucchsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pucchsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pucchsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pucchsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-nr-pucchsim.chart" . }}
|
||||||
|
{{ include "oai-nr-pucchsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pucchsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-nr-pucchsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-pucchsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-nr-pucchsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-pucchsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-nr-pucchsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-pucchsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-nr-pucchsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-nr-pucchsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015109" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-pucchsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-nr-pucchsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-nr-pucchsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-nr-pucchsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-nr-pucchsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-nr-ulschsim
|
||||||
|
description: A Helm subchart for nr-ulschsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- nr-ulschsim
|
||||||
|
- RAN
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-nr-ulschsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-nr-ulschsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-nr-ulschsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-nr-ulschsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulschsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulschsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulschsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulschsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-nr-ulschsim.chart" . }}
|
||||||
|
{{ include "oai-nr-ulschsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulschsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-nr-ulschsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulschsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-nr-ulschsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-ulschsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-nr-ulschsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-ulschsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-nr-ulschsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-nr-ulschsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015108" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-ulschsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-nr-ulschsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-nr-ulschsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-nr-ulschsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-nr-ulschsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-nr-ulsim
|
||||||
|
description: A Helm subchart for nr-ulsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- nr-ulsim
|
||||||
|
- RAN
|
||||||
|
- 5G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-nr-ulsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-nr-ulsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-nr-ulsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-nr-ulsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-nr-ulsim.chart" . }}
|
||||||
|
{{ include "oai-nr-ulsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-nr-ulsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-nr-ulsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-nr-ulsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-ulsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-nr-ulsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-ulsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-nr-ulsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-nr-ulsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015111" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-nr-ulsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-nr-ulsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-nr-ulsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-nr-ulsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-nr-ulsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-polartest
|
||||||
|
description: A Helm subchart for polartest network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- polartest
|
||||||
|
- RAN
|
||||||
|
- 4G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-polartest.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-polartest.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-polartest.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-polartest.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-polartest.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-polartest.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-polartest.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-polartest.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-polartest.chart" . }}
|
||||||
|
{{ include "oai-polartest.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-polartest.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-polartest.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-polartest.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-polartest.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-polartest.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-polartest.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-polartest.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-polartest
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-polartest/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015103" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-polartest.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-polartest
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-polartest.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-polartest.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-polartest-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-smallblocktest
|
||||||
|
description: A Helm subchart for smallblocktest network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- smallblocktest
|
||||||
|
- RAN
|
||||||
|
- 4G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-smallblocktest.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-smallblocktest.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-smallblocktest.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-smallblocktest.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-smallblocktest.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-smallblocktest.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-smallblocktest.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-smallblocktest.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-smallblocktest.chart" . }}
|
||||||
|
{{ include "oai-smallblocktest.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-smallblocktest.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-smallblocktest.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-smallblocktest.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-smallblocktest.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-smallblocktest.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-smallblocktest.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-smallblocktest.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-smallblock
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-smallblocktest/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015107" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-smallblocktest.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-smallblocktest
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-smallblocktest.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-smallblocktest.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-smallblocktest-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
name: oai-ulsim
|
||||||
|
description: A Helm subchart for ulsim network function
|
||||||
|
|
||||||
|
# A chart can be either an 'application' or a 'library' chart.
|
||||||
|
#
|
||||||
|
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||||
|
# to be deployed.
|
||||||
|
#
|
||||||
|
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||||
|
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||||
|
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||||
|
type: application
|
||||||
|
|
||||||
|
icon: http://www.openairinterface.org/wp-content/uploads/2015/06/cropped-oai_final_logo.png
|
||||||
|
|
||||||
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
|
# to the chart and its templates, including the app version.
|
||||||
|
version: 0.1.1
|
||||||
|
|
||||||
|
# This is the version number of the application being deployed. This version number should be
|
||||||
|
# incremented each time you make changes to the application.
|
||||||
|
appVersion: v1
|
||||||
|
|
||||||
|
keywords:
|
||||||
|
- Physical Simulator
|
||||||
|
- ulsim
|
||||||
|
- RAN
|
||||||
|
- 4G
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- https://gitlab.eurecom.fr/oai/openairinterface5g
|
||||||
|
|
||||||
|
maintainers:
|
||||||
|
- name: OPENAIRINTERFACE
|
||||||
|
email: contact@openairinterface.org
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
1. Get the application URL by running these commands:
|
||||||
|
{{- if contains "NodePort" .Values.service.type }}
|
||||||
|
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "oai-ulsim.fullname" . }})
|
||||||
|
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||||
|
echo http://$NODE_IP:$NODE_PORT
|
||||||
|
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||||
|
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||||
|
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "oai-ulsim.fullname" . }}'
|
||||||
|
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "oai-ulsim.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||||
|
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||||
|
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||||
|
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "oai-ulsim.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||||
|
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||||
|
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
{{/* vim: set filetype=mustache: */}}
|
||||||
|
{{/*
|
||||||
|
Expand the name of the chart.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ulsim.name" -}}
|
||||||
|
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create a default fully qualified app name.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
If release name contains chart name it will be used as a full name.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ulsim.fullname" -}}
|
||||||
|
{{- if .Values.fullnameOverride -}}
|
||||||
|
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||||
|
{{- if contains $name .Release.Name -}}
|
||||||
|
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create chart name and version as used by the chart label.
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ulsim.chart" -}}
|
||||||
|
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Common labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ulsim.labels" -}}
|
||||||
|
helm.sh/chart: {{ include "oai-ulsim.chart" . }}
|
||||||
|
{{ include "oai-ulsim.selectorLabels" . }}
|
||||||
|
{{- if .Chart.AppVersion }}
|
||||||
|
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||||
|
{{- end }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Selector labels
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ulsim.selectorLabels" -}}
|
||||||
|
app.kubernetes.io/name: {{ include "oai-ulsim.name" . }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "oai-ulsim.serviceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccount.create -}}
|
||||||
|
{{ default (include "oai-ulsim.fullname" .) .Values.serviceAccount.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccount.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-ulsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "oai-ulsim.selectorLabels" . | nindent 6 }}
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
{{- include "oai-ulsim.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
{{- if .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: physim
|
||||||
|
image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.version }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
name: oai-ulsim
|
||||||
|
# volumeMounts:
|
||||||
|
# - mountPath: /opt/oai-ulsim/certs
|
||||||
|
# name: certs
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- >
|
||||||
|
export OPENAIR_DIR=/opt/oai-physim &&
|
||||||
|
cd cmake_targets/autotests &&
|
||||||
|
./run_exec_autotests.bash -g "015101" -q -np -b &&
|
||||||
|
echo "FINISHED" &&
|
||||||
|
sleep infinity
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
|
restartPolicy: Always
|
||||||
|
schedulerName: default-scheduler
|
||||||
|
serviceAccountName: {{ .Values.global.serviceAccountName }}
|
||||||
|
terminationGracePeriodSeconds: 30
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}
|
||||||
|
labels:
|
||||||
|
{{- include "oai-ulsim.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
type: {{ .Values.service.type }}
|
||||||
|
{{- if contains "ClusterIP" .Values.service.type }}
|
||||||
|
clusterIP: None
|
||||||
|
{{- end }}
|
||||||
|
ports:
|
||||||
|
- name: oai-ulsim
|
||||||
|
# Port accessible outside cluster
|
||||||
|
port: {{ .Values.service.port }}
|
||||||
|
# Port to forward to inside the pod
|
||||||
|
targetPort: {{ .Values.service.Port }}
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
{{- include "oai-ulsim.selectorLabels" . | nindent 4 }}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
# Default values for oai-ulsim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
|
||||||
|
image:
|
||||||
|
registry: local
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: temp
|
||||||
|
# pullPolicy: IfNotPresent or Never or Always
|
||||||
|
pullPolicy: Always
|
||||||
|
|
||||||
|
imagePullSecrets: []
|
||||||
|
|
||||||
|
nameOverride: ""
|
||||||
|
fullnameOverride: ""
|
||||||
|
|
||||||
|
serviceAccount:
|
||||||
|
# Specifies whether a service account should be created
|
||||||
|
create: true
|
||||||
|
# Annotations to add to the service account
|
||||||
|
annotations: {}
|
||||||
|
# The name of the service account to use.
|
||||||
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
|
name: "oai-ulsim-sa"
|
||||||
|
|
||||||
|
podSecurityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
runAsGroup: 0
|
||||||
|
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
# capabilities:
|
||||||
|
# drop:
|
||||||
|
# - ALL
|
||||||
|
# readOnlyRootFilesystem: true
|
||||||
|
# runAsNonRoot: true
|
||||||
|
# runAsUser: 1000
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
resources: {}
|
||||||
|
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||||
|
# choice for the user. This also increases chances charts run on environments with little
|
||||||
|
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||||
|
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||||
|
# limits:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
# requests:
|
||||||
|
# cpu: 100m
|
||||||
|
# memory: 128Mi
|
||||||
|
|
||||||
|
nodeSelector: {}
|
||||||
|
|
||||||
|
tolerations: []
|
||||||
|
|
||||||
|
affinity: {}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
apiVersion: rbac.authorization.k8s.io/v1beta1
|
||||||
|
kind: ClusterRoleBinding
|
||||||
|
metadata:
|
||||||
|
name: {{ .Chart.Name }}-{{ .Values.global.namespace }}-rbac
|
||||||
|
roleRef:
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
kind: ClusterRole
|
||||||
|
name: cluster-admin
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: {{ .Values.global.serviceAccountName }}
|
||||||
|
namespace: {{ .Values.global.namespace }}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ServiceAccount
|
||||||
|
metadata:
|
||||||
|
name: {{ .Values.global.serviceAccountName }}
|
||||||
@@ -0,0 +1,84 @@
|
|||||||
|
# Default values for oai-physim.
|
||||||
|
# This is a YAML-formatted file.
|
||||||
|
# Declare variables to be passed into your templates.
|
||||||
|
|
||||||
|
global:
|
||||||
|
serviceAccountName: oai-physim-sa
|
||||||
|
namespace: "oaicicd-ran-tmp"
|
||||||
|
image:
|
||||||
|
repository: image-registry.openshift-image-registry.svc:5000/oaicicd-ran-tmp/oai-physim
|
||||||
|
version: TAG
|
||||||
|
|
||||||
|
## Declaring values specific to coressponding physim to overwrite
|
||||||
|
|
||||||
|
dlsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
ulsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
ldpctest:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
polartest:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
nr-pbchsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
nr-dlsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
nr-dlschsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
smallblocktest:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
nr-ulschsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
nr-pucchsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
nr-ulsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
|
|
||||||
|
nr-prachsim:
|
||||||
|
replicaCount: 1
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 80
|
||||||
@@ -176,6 +176,30 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
stage ("Image Test Processes") {
|
||||||
|
parallel {
|
||||||
|
stage ("Physical Simulators") {
|
||||||
|
when { expression {doMandatoryTests} }
|
||||||
|
steps {
|
||||||
|
script {
|
||||||
|
triggerSlaveJob ('RAN-PhySim-Cluster', 'Test-Physim-Cluster')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
post {
|
||||||
|
always {
|
||||||
|
script {
|
||||||
|
finalizeSlaveJob('RAN-PhySim-Cluster')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
failure {
|
||||||
|
script {
|
||||||
|
currentBuild.result = 'FAILURE'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
post {
|
post {
|
||||||
always {
|
always {
|
||||||
|
|||||||
@@ -196,16 +196,6 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stage ("Start VM -- phy-sim") {
|
|
||||||
steps {
|
|
||||||
lock (vmResource) {
|
|
||||||
timeout (time: 5, unit: 'MINUTES') {
|
|
||||||
sh "./ci-scripts/oai-ci-vm-tool build --workspace $WORKSPACE --variant phy-sim --job-name ${JOB_NAME} --build-id ${BUILD_ID} --daemon"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
stage ("Start VM -- enb-ethernet") {
|
stage ("Start VM -- enb-ethernet") {
|
||||||
steps {
|
steps {
|
||||||
lock (vmResource) {
|
lock (vmResource) {
|
||||||
@@ -255,15 +245,6 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage ("Build physical simulators") {
|
|
||||||
steps {
|
|
||||||
gitlabCommitStatus(name: "Build phy-sim") {
|
|
||||||
timeout (time: 45, unit: 'MINUTES') {
|
|
||||||
sh "./ci-scripts/oai-ci-vm-tool wait --workspace $WORKSPACE --variant phy-sim --job-name ${JOB_NAME} --build-id ${BUILD_ID} --keep-vm-alive"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage ("Build eNB-ethernet") {
|
stage ("Build eNB-ethernet") {
|
||||||
steps {
|
steps {
|
||||||
gitlabCommitStatus(name: "Build eNB-ethernet") {
|
gitlabCommitStatus(name: "Build eNB-ethernet") {
|
||||||
@@ -296,9 +277,9 @@ pipeline {
|
|||||||
script {
|
script {
|
||||||
dir ('archives') {
|
dir ('archives') {
|
||||||
if (fileExists('red_hat')) {
|
if (fileExists('red_hat')) {
|
||||||
sh "zip -r -qq vm_build_logs.zip basic_sim phy_sim enb_eth ue_eth gnb_usrp nr_ue_usrp red_hat"
|
sh "zip -r -qq vm_build_logs.zip basic_sim enb_eth ue_eth gnb_usrp nr_ue_usrp red_hat"
|
||||||
} else {
|
} else {
|
||||||
sh "zip -r -qq vm_build_logs.zip basic_sim phy_sim enb_eth ue_eth gnb_usrp nr_ue_usrp"
|
sh "zip -r -qq vm_build_logs.zip basic_sim enb_eth ue_eth gnb_usrp nr_ue_usrp"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(fileExists('archives/vm_build_logs.zip')) {
|
if(fileExists('archives/vm_build_logs.zip')) {
|
||||||
@@ -332,26 +313,6 @@ pipeline {
|
|||||||
parallel {
|
parallel {
|
||||||
stage ("VM-based tests") {
|
stage ("VM-based tests") {
|
||||||
stages {
|
stages {
|
||||||
stage ("Test physical simulators") {
|
|
||||||
when {
|
|
||||||
expression {doMandatoryTests}
|
|
||||||
}
|
|
||||||
steps {
|
|
||||||
lock (vmResource) {
|
|
||||||
script {
|
|
||||||
timeout (time: 90, unit: 'MINUTES') {
|
|
||||||
try {
|
|
||||||
gitlabCommitStatus(name: "Test phy-sim") {
|
|
||||||
sh "./ci-scripts/oai-ci-vm-tool test --workspace $WORKSPACE --variant phy-sim --job-name ${JOB_NAME} --build-id ${BUILD_ID}"
|
|
||||||
}
|
|
||||||
} catch (Exception e) {
|
|
||||||
currentBuild.result = 'FAILURE'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage ("Build Flexran Controller") {
|
stage ("Build Flexran Controller") {
|
||||||
when {
|
when {
|
||||||
expression {doFlexranCtrlTest && doMandatoryTests}
|
expression {doFlexranCtrlTest && doMandatoryTests}
|
||||||
@@ -716,7 +677,7 @@ pipeline {
|
|||||||
script {
|
script {
|
||||||
if (doMandatoryTests) {
|
if (doMandatoryTests) {
|
||||||
dir ('archives') {
|
dir ('archives') {
|
||||||
sh "if [ -d basic_sim/test ] || [ -d phy_sim/test ] || [ -d l2_sim/test ]; then zip -r -qq vm_tests_logs.zip */test ; fi"
|
sh "if [ -d basic_sim/test ] || [ -d rf_sim/test ] || [ -d l2_sim/test ]; then zip -r -qq vm_tests_logs.zip */test ; fi"
|
||||||
}
|
}
|
||||||
if(fileExists('archives/vm_tests_logs.zip')) {
|
if(fileExists('archives/vm_tests_logs.zip')) {
|
||||||
archiveArtifacts artifacts: 'archives/vm_tests_logs.zip'
|
archiveArtifacts artifacts: 'archives/vm_tests_logs.zip'
|
||||||
|
|||||||
@@ -0,0 +1,233 @@
|
|||||||
|
#!/bin/groovy
|
||||||
|
/*
|
||||||
|
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
|
||||||
|
* contributor license agreements. See the NOTICE file distributed with
|
||||||
|
* this work for additional information regarding copyright ownership.
|
||||||
|
* The OpenAirInterface Software Alliance licenses this file to You under
|
||||||
|
* the OAI Public License, Version 1.1 (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.openairinterface.org/?page_id=698
|
||||||
|
*
|
||||||
|
* 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.
|
||||||
|
*-------------------------------------------------------------------------------
|
||||||
|
* For more information about the OpenAirInterface (OAI) Software Alliance:
|
||||||
|
* contact@openairinterface.org
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Location of the executor node
|
||||||
|
def pythonExecutor = params.pythonExecutor
|
||||||
|
|
||||||
|
// Location of the test XML file to be run
|
||||||
|
def testXMLFile = params.pythonTestXmlFile
|
||||||
|
def mainPythonAllXmlFiles = ""
|
||||||
|
def buildStageStatus = true
|
||||||
|
|
||||||
|
// Name of the test stage
|
||||||
|
def testStageName = params.pipelineTestStageName
|
||||||
|
|
||||||
|
// Name of the resource
|
||||||
|
def ciEpcResource = params.epcResource
|
||||||
|
|
||||||
|
// Global Parameters. Normally they should be populated when the master job
|
||||||
|
// triggers the slave job with parameters
|
||||||
|
def eNB_Repository
|
||||||
|
def eNB_Branch
|
||||||
|
def eNB_CommitID
|
||||||
|
def eNB_AllowMergeRequestProcess = false
|
||||||
|
def eNB_TargetBranch
|
||||||
|
|
||||||
|
// Flags
|
||||||
|
def scmEvent = false
|
||||||
|
def upstreamEvent = false
|
||||||
|
|
||||||
|
//-------------------------------------------------------------------------------
|
||||||
|
// Pipeline start
|
||||||
|
pipeline {
|
||||||
|
agent {
|
||||||
|
label pythonExecutor
|
||||||
|
}
|
||||||
|
options {
|
||||||
|
disableConcurrentBuilds()
|
||||||
|
timestamps()
|
||||||
|
ansiColor('xterm')
|
||||||
|
lock(ciEpcResource)
|
||||||
|
}
|
||||||
|
|
||||||
|
stages {
|
||||||
|
stage ('Verify Parameters') {
|
||||||
|
steps {
|
||||||
|
script {
|
||||||
|
echo '\u2705 \u001B[32mVerify Parameters\u001B[0m'
|
||||||
|
|
||||||
|
JOB_TIMESTAMP = sh returnStdout: true, script: 'date --utc --rfc-3339=seconds | sed -e "s#+00:00##"'
|
||||||
|
JOB_TIMESTAMP = JOB_TIMESTAMP.trim()
|
||||||
|
|
||||||
|
def allParametersPresent = true
|
||||||
|
|
||||||
|
// It is already to late to check it
|
||||||
|
if (params.pythonExecutor != null) {
|
||||||
|
echo "eNB CI executor node : ${pythonExecutor}"
|
||||||
|
}
|
||||||
|
// If not present picking a default Stage Name
|
||||||
|
if (params.pipelineTestStageName == null) {
|
||||||
|
// picking default
|
||||||
|
testStageName = 'Template Test Stage'
|
||||||
|
}
|
||||||
|
|
||||||
|
if (params.smartphonesResource == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.eNB_IPAddress == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.eNB_SourceCodePath == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.eNB_Credentials == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
// the following 4 parameters should be pushed by the master trigger
|
||||||
|
// if not present, take the job GIT variables (used for developing)
|
||||||
|
if (params.eNB_Repository == null) {
|
||||||
|
eNB_Repository = env.GIT_URL
|
||||||
|
} else {
|
||||||
|
eNB_Repository = params.eNB_Repository
|
||||||
|
}
|
||||||
|
echo "eNB_Repository : ${eNB_Repository}"
|
||||||
|
if (params.eNB_Branch == null) {
|
||||||
|
eNB_Branch = env.GIT_BRANCH
|
||||||
|
} else {
|
||||||
|
eNB_Branch = params.eNB_Branch
|
||||||
|
}
|
||||||
|
echo "eNB_Branch : ${eNB_Branch}"
|
||||||
|
if (params.eNB_CommitID == null) {
|
||||||
|
eNB_CommitID = env.GIT_COMMIT
|
||||||
|
} else {
|
||||||
|
eNB_CommitID = params.eNB_CommitID
|
||||||
|
}
|
||||||
|
echo "eNB_CommitID : ${eNB_CommitID}"
|
||||||
|
if (params.eNB_mergeRequest != null) {
|
||||||
|
eNB_AllowMergeRequestProcess = params.eNB_mergeRequest
|
||||||
|
if (eNB_AllowMergeRequestProcess) {
|
||||||
|
if (params.eNB_TargetBranch != null) {
|
||||||
|
eNB_TargetBranch = params.eNB_TargetBranch
|
||||||
|
} else {
|
||||||
|
eNB_TargetBranch = 'develop'
|
||||||
|
}
|
||||||
|
echo "eNB_TargetBranch : ${eNB_TargetBranch}"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (params.EPC_IPAddress == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.EPC_Type == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.EPC_SourceCodePath == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.EPC_Credentials == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
|
||||||
|
if (params.ADB_IPAddress == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.ADB_Credentials == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.OC_Credentials == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (params.OC_ProjectName == null) {
|
||||||
|
allParametersPresent = false
|
||||||
|
}
|
||||||
|
if (allParametersPresent) {
|
||||||
|
echo "All parameters are present"
|
||||||
|
if (eNB_AllowMergeRequestProcess) {
|
||||||
|
sh "git fetch"
|
||||||
|
sh "./ci-scripts/doGitLabMerge.sh --src-branch ${eNB_Branch} --src-commit ${eNB_CommitID} --target-branch ${eNB_TargetBranch} --target-commit latest"
|
||||||
|
} else {
|
||||||
|
sh "git fetch"
|
||||||
|
sh "git checkout -f ${eNB_CommitID}"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
echo "Some parameters are missing"
|
||||||
|
sh "./ci-scripts/fail.sh"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
stage ("Deploy and Test") {
|
||||||
|
steps {
|
||||||
|
script {
|
||||||
|
dir ('ci-scripts') {
|
||||||
|
echo "\u2705 \u001B[32m${testStageName}\u001B[0m"
|
||||||
|
// If not present picking a default XML file
|
||||||
|
if (params.pythonTestXmlFile == null) {
|
||||||
|
// picking default
|
||||||
|
testXMLFile = 'xml_files/enb_usrpB210_band7_50PRB.xml'
|
||||||
|
echo "Test XML file(default): ${testXMLFile}"
|
||||||
|
mainPythonAllXmlFiles += "--XMLTestFile=" + testXMLFile + " "
|
||||||
|
} else {
|
||||||
|
String[] myXmlTestSuite = testXMLFile.split("\\r?\\n")
|
||||||
|
for (xmlFile in myXmlTestSuite) {
|
||||||
|
if (fileExists(xmlFile)) {
|
||||||
|
mainPythonAllXmlFiles += "--XMLTestFile=" + xmlFile + " "
|
||||||
|
echo "Test XML file : ${xmlFile}"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
withCredentials([
|
||||||
|
[$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.eNB_Credentials}", usernameVariable: 'eNB_Username', passwordVariable: 'eNB_Password'],
|
||||||
|
[$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.EPC_Credentials}", usernameVariable: 'EPC_Username', passwordVariable: 'EPC_Password'],
|
||||||
|
[$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.ADB_Credentials}", usernameVariable: 'ADB_Username', passwordVariable: 'ADB_Password'],
|
||||||
|
[$class: 'UsernamePasswordMultiBinding', credentialsId: "${params.OC_Credentials}", usernameVariable: 'OC_Username', passwordVariable: 'OC_Password']
|
||||||
|
]) {
|
||||||
|
sh "python3 main.py --mode=InitiateHtml --ranRepository=${eNB_Repository} --ranBranch=${eNB_Branch} --ranCommitID=${eNB_CommitID} --ranAllowMerge=${eNB_AllowMergeRequestProcess} --ranTargetBranch=${eNB_TargetBranch} --ADBIPAddress=${params.ADB_IPAddress} --ADBUserName=${ADB_Username} --ADBPassword=${ADB_Password} ${mainPythonAllXmlFiles}"
|
||||||
|
String[] myXmlTestSuite = testXMLFile.split("\\r?\\n")
|
||||||
|
for (xmlFile in myXmlTestSuite) {
|
||||||
|
if (fileExists(xmlFile)) {
|
||||||
|
try {
|
||||||
|
sh "python3 main.py --mode=TesteNB --eNBIPAddress=${params.eNB_IPAddress} --ranRepository=${eNB_Repository} --ranBranch=${eNB_Branch} --ranCommitID=${eNB_CommitID} --ranAllowMerge=${eNB_AllowMergeRequestProcess} --ranTargetBranch=${eNB_TargetBranch} --eNBUserName=${eNB_Username} --eNBPassword=${eNB_Password} --eNBSourceCodePath=${params.eNB_SourceCodePath} --EPCIPAddress=${params.EPC_IPAddress} --EPCType=${params.EPC_Type} --EPCUserName=${EPC_Username} --EPCPassword=${EPC_Password} --EPCSourceCodePath=${params.EPC_SourceCodePath} --ADBIPAddress=${params.ADB_IPAddress} --ADBUserName=${ADB_Username} --ADBPassword=${ADB_Password} --XMLTestFile=${xmlFile} --OCUserName=${OC_Username} --OCPassword=${OC_Password} --OCProjectName=${OC_ProjectName}"
|
||||||
|
} catch (Exception e) {
|
||||||
|
currentBuild.result = 'FAILURE'
|
||||||
|
buildStageStatus = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
sh "python3 main.py --mode=FinalizeHtml --finalStatus=${buildStageStatus} --eNBIPAddress=${params.eNB_IPAddress} --eNBUserName=${eNB_Username} --eNBPassword=${eNB_Password}"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage ("Log Collection") {
|
||||||
|
steps {
|
||||||
|
script {
|
||||||
|
dir ('ci-scripts') {
|
||||||
|
// Zipping all archived log files
|
||||||
|
sh "zip -r -qq physim_deploytest_logs_${env.BUILD_ID}.zip physim_test_logs_*/*"
|
||||||
|
sh "rm -rf physim_test_logs_*/"
|
||||||
|
if (fileExists("physim_deploytest_logs_${env.BUILD_ID}.zip")) {
|
||||||
|
archiveArtifacts artifacts: "physim_deploytest_logs_${env.BUILD_ID}.zip"
|
||||||
|
}
|
||||||
|
if (fileExists("test_results.html")) {
|
||||||
|
sh "mv test_results.html test_results_${env.JOB_NAME}.html"
|
||||||
|
sh "sed -i -e 's#TEMPLATE_JOB_NAME#${JOB_NAME}#' -e 's@build #TEMPLATE_BUILD_ID@build #${BUILD_ID}@' -e 's#Build-ID: TEMPLATE_BUILD_ID#Build-ID: <a href=\"${BUILD_URL}\">${BUILD_ID}</a>#' -e 's#TEMPLATE_STAGE_NAME#${testStageName}#' test_results_${JOB_NAME}.html"
|
||||||
|
archiveArtifacts artifacts: "test_results_${env.JOB_NAME}.html"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -41,7 +41,7 @@ import constants as CONST
|
|||||||
#-----------------------------------------------------------
|
#-----------------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA,PHYSIM):
|
||||||
|
|
||||||
|
|
||||||
py_param_file_present = False
|
py_param_file_present = False
|
||||||
@@ -81,6 +81,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
ldpc.ranRepository=matchReg.group(1)
|
ldpc.ranRepository=matchReg.group(1)
|
||||||
CONTAINERS.ranRepository=matchReg.group(1)
|
CONTAINERS.ranRepository=matchReg.group(1)
|
||||||
SCA.ranRepository=matchReg.group(1)
|
SCA.ranRepository=matchReg.group(1)
|
||||||
|
PHYSIM.ranRepository=matchReg.group(1)
|
||||||
elif re.match('^\-\-eNB_AllowMerge=(.+)$|^\-\-ranAllowMerge=(.+)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNB_AllowMerge=(.+)$|^\-\-ranAllowMerge=(.+)$', myArgv, re.IGNORECASE):
|
||||||
if re.match('^\-\-eNB_AllowMerge=(.+)$', myArgv, re.IGNORECASE):
|
if re.match('^\-\-eNB_AllowMerge=(.+)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNB_AllowMerge=(.+)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNB_AllowMerge=(.+)$', myArgv, re.IGNORECASE)
|
||||||
@@ -94,6 +95,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
HTML.ranAllowMerge=True
|
HTML.ranAllowMerge=True
|
||||||
CONTAINERS.ranAllowMerge=True
|
CONTAINERS.ranAllowMerge=True
|
||||||
SCA.ranAllowMerge=True
|
SCA.ranAllowMerge=True
|
||||||
|
PHYSIM.ranAllowMerge=True
|
||||||
elif re.match('^\-\-eNBBranch=(.+)$|^\-\-ranBranch=(.+)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNBBranch=(.+)$|^\-\-ranBranch=(.+)$', myArgv, re.IGNORECASE):
|
||||||
if re.match('^\-\-eNBBranch=(.+)$', myArgv, re.IGNORECASE):
|
if re.match('^\-\-eNBBranch=(.+)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNBBranch=(.+)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNBBranch=(.+)$', myArgv, re.IGNORECASE)
|
||||||
@@ -105,6 +107,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
ldpc.ranBranch=matchReg.group(1)
|
ldpc.ranBranch=matchReg.group(1)
|
||||||
CONTAINERS.ranBranch=matchReg.group(1)
|
CONTAINERS.ranBranch=matchReg.group(1)
|
||||||
SCA.ranBranch=matchReg.group(1)
|
SCA.ranBranch=matchReg.group(1)
|
||||||
|
PHYSIM.ranBranch=matchReg.group(1)
|
||||||
elif re.match('^\-\-eNBCommitID=(.*)$|^\-\-ranCommitID=(.*)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNBCommitID=(.*)$|^\-\-ranCommitID=(.*)$', myArgv, re.IGNORECASE):
|
||||||
if re.match('^\-\-eNBCommitID=(.*)$', myArgv, re.IGNORECASE):
|
if re.match('^\-\-eNBCommitID=(.*)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNBCommitID=(.*)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNBCommitID=(.*)$', myArgv, re.IGNORECASE)
|
||||||
@@ -116,6 +119,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
ldpc.ranCommitID=matchReg.group(1)
|
ldpc.ranCommitID=matchReg.group(1)
|
||||||
CONTAINERS.ranCommitID=matchReg.group(1)
|
CONTAINERS.ranCommitID=matchReg.group(1)
|
||||||
SCA.ranCommitID=matchReg.group(1)
|
SCA.ranCommitID=matchReg.group(1)
|
||||||
|
PHYSIM.ranCommitID=matchReg.group(1)
|
||||||
elif re.match('^\-\-eNBTargetBranch=(.*)$|^\-\-ranTargetBranch=(.*)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNBTargetBranch=(.*)$|^\-\-ranTargetBranch=(.*)$', myArgv, re.IGNORECASE):
|
||||||
if re.match('^\-\-eNBTargetBranch=(.*)$', myArgv, re.IGNORECASE):
|
if re.match('^\-\-eNBTargetBranch=(.*)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNBTargetBranch=(.*)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNBTargetBranch=(.*)$', myArgv, re.IGNORECASE)
|
||||||
@@ -127,6 +131,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
ldpc.ranTargetBranch=matchReg.group(1)
|
ldpc.ranTargetBranch=matchReg.group(1)
|
||||||
CONTAINERS.ranTargetBranch=matchReg.group(1)
|
CONTAINERS.ranTargetBranch=matchReg.group(1)
|
||||||
SCA.ranTargetBranch=matchReg.group(1)
|
SCA.ranTargetBranch=matchReg.group(1)
|
||||||
|
PHYSIM.ranTargetBranch=matchReg.group(1)
|
||||||
elif re.match('^\-\-eNBIPAddress=(.+)$|^\-\-eNB[1-2]IPAddress=(.+)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNBIPAddress=(.+)$|^\-\-eNB[1-2]IPAddress=(.+)$', myArgv, re.IGNORECASE):
|
||||||
if re.match('^\-\-eNBIPAddress=(.+)$', myArgv, re.IGNORECASE):
|
if re.match('^\-\-eNBIPAddress=(.+)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNBIPAddress=(.+)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNBIPAddress=(.+)$', myArgv, re.IGNORECASE)
|
||||||
@@ -134,6 +139,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
ldpc.eNBIpAddr=matchReg.group(1)
|
ldpc.eNBIpAddr=matchReg.group(1)
|
||||||
CONTAINERS.eNBIPAddress=matchReg.group(1)
|
CONTAINERS.eNBIPAddress=matchReg.group(1)
|
||||||
SCA.eNBIPAddress=matchReg.group(1)
|
SCA.eNBIPAddress=matchReg.group(1)
|
||||||
|
PHYSIM.eNBIPAddress=matchReg.group(1)
|
||||||
elif re.match('^\-\-eNB1IPAddress=(.+)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNB1IPAddress=(.+)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNB1IPAddress=(.+)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNB1IPAddress=(.+)$', myArgv, re.IGNORECASE)
|
||||||
RAN.eNB1IPAddress=matchReg.group(1)
|
RAN.eNB1IPAddress=matchReg.group(1)
|
||||||
@@ -149,6 +155,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
ldpc.eNBUserName=matchReg.group(1)
|
ldpc.eNBUserName=matchReg.group(1)
|
||||||
CONTAINERS.eNBUserName=matchReg.group(1)
|
CONTAINERS.eNBUserName=matchReg.group(1)
|
||||||
SCA.eNBUserName=matchReg.group(1)
|
SCA.eNBUserName=matchReg.group(1)
|
||||||
|
PHYSIM.eNBUserName=matchReg.group(1)
|
||||||
elif re.match('^\-\-eNB1UserName=(.+)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNB1UserName=(.+)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNB1UserName=(.+)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNB1UserName=(.+)$', myArgv, re.IGNORECASE)
|
||||||
RAN.eNB1UserName=matchReg.group(1)
|
RAN.eNB1UserName=matchReg.group(1)
|
||||||
@@ -164,6 +171,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
ldpc.eNBPassWord=matchReg.group(1)
|
ldpc.eNBPassWord=matchReg.group(1)
|
||||||
CONTAINERS.eNBPassword=matchReg.group(1)
|
CONTAINERS.eNBPassword=matchReg.group(1)
|
||||||
SCA.eNBPassword=matchReg.group(1)
|
SCA.eNBPassword=matchReg.group(1)
|
||||||
|
PHYSIM.eNBPassword=matchReg.group(1)
|
||||||
elif re.match('^\-\-eNB1Password=(.+)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNB1Password=(.+)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNB1Password=(.+)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNB1Password=(.+)$', myArgv, re.IGNORECASE)
|
||||||
RAN.eNB1Password=matchReg.group(1)
|
RAN.eNB1Password=matchReg.group(1)
|
||||||
@@ -179,6 +187,7 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
ldpc.eNBSourceCodePath=matchReg.group(1)
|
ldpc.eNBSourceCodePath=matchReg.group(1)
|
||||||
CONTAINERS.eNBSourceCodePath=matchReg.group(1)
|
CONTAINERS.eNBSourceCodePath=matchReg.group(1)
|
||||||
SCA.eNBSourceCodePath=matchReg.group(1)
|
SCA.eNBSourceCodePath=matchReg.group(1)
|
||||||
|
PHYSIM.eNBSourceCodePath=matchReg.group(1)
|
||||||
elif re.match('^\-\-eNB1SourceCodePath=(.+)$', myArgv, re.IGNORECASE):
|
elif re.match('^\-\-eNB1SourceCodePath=(.+)$', myArgv, re.IGNORECASE):
|
||||||
matchReg = re.match('^\-\-eNB1SourceCodePath=(.+)$', myArgv, re.IGNORECASE)
|
matchReg = re.match('^\-\-eNB1SourceCodePath=(.+)$', myArgv, re.IGNORECASE)
|
||||||
RAN.eNB1SourceCodePath=matchReg.group(1)
|
RAN.eNB1SourceCodePath=matchReg.group(1)
|
||||||
@@ -248,6 +257,15 @@ def ArgsParse(argvs,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA):
|
|||||||
finalStatus = matchReg.group(1)
|
finalStatus = matchReg.group(1)
|
||||||
if ((finalStatus == 'true') or (finalStatus == 'True')):
|
if ((finalStatus == 'true') or (finalStatus == 'True')):
|
||||||
CiTestObj.finalStatus = True
|
CiTestObj.finalStatus = True
|
||||||
|
elif re.match('^\-\-OCUserName=(.+)$', myArgv, re.IGNORECASE):
|
||||||
|
matchReg = re.match('^\-\-OCUserName=(.+)$', myArgv, re.IGNORECASE)
|
||||||
|
PHYSIM.OCUserName = matchReg.group(1)
|
||||||
|
elif re.match('^\-\-OCPassword=(.+)$', myArgv, re.IGNORECASE):
|
||||||
|
matchReg = re.match('^\-\-OCPassword=(.+)$', myArgv, re.IGNORECASE)
|
||||||
|
PHYSIM.OCPassword = matchReg.group(1)
|
||||||
|
elif re.match('^\-\-OCProjectName=(.+)$', myArgv, re.IGNORECASE):
|
||||||
|
matchReg = re.match('^\-\-OCProjectName=(.+)$', myArgv, re.IGNORECASE)
|
||||||
|
PHYSIM.OCProjectName = matchReg.group(1)
|
||||||
else:
|
else:
|
||||||
HELP.GenericHelp(CONST.Version)
|
HELP.GenericHelp(CONST.Version)
|
||||||
sys.exit('Invalid Parameter: ' + myArgv)
|
sys.exit('Invalid Parameter: ' + myArgv)
|
||||||
|
|||||||
@@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
while true
|
||||||
|
do
|
||||||
|
echo "gNB will be started automatically..."
|
||||||
|
sleep 1
|
||||||
|
sudo .././cmake_targets/ran_build/build/nr-softmodem -E -O ../targets/PROJECTS/GENERIC-LTE-EPC/CONF/testing_gnb.conf
|
||||||
|
done
|
||||||
@@ -62,7 +62,7 @@ function build_on_vm {
|
|||||||
echo "ARCHIVES_LOC = $ARCHIVES_LOC"
|
echo "ARCHIVES_LOC = $ARCHIVES_LOC"
|
||||||
echo "BUILD_OPTIONS = $BUILD_OPTIONS"
|
echo "BUILD_OPTIONS = $BUILD_OPTIONS"
|
||||||
|
|
||||||
if [[ "$VM_NAME" == *"-enb-usrp"* ]] || [[ "$VM_NAME" == *"-cppcheck"* ]]
|
if [[ "$VM_NAME" == *"-enb-usrp"* ]] || [[ "$VM_NAME" == *"-cppcheck"* ]] || [[ "$VM_NAME" == *"-phy-sim"* ]]
|
||||||
then
|
then
|
||||||
echo "This VM type is no longer supported in the pipeline framework"
|
echo "This VM type is no longer supported in the pipeline framework"
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -88,6 +88,7 @@ class Containerize():
|
|||||||
self.host = ''
|
self.host = ''
|
||||||
self.allImagesSize = {}
|
self.allImagesSize = {}
|
||||||
self.collectInfo = {}
|
self.collectInfo = {}
|
||||||
|
|
||||||
#-----------------------------------------------------------
|
#-----------------------------------------------------------
|
||||||
# Container management functions
|
# Container management functions
|
||||||
#-----------------------------------------------------------
|
#-----------------------------------------------------------
|
||||||
@@ -335,6 +336,31 @@ class Containerize():
|
|||||||
errorandwarnings['warnings'] = warningsNo
|
errorandwarnings['warnings'] = warningsNo
|
||||||
errorandwarnings['status'] = status
|
errorandwarnings['status'] = status
|
||||||
files[fil] = errorandwarnings
|
files[fil] = errorandwarnings
|
||||||
|
# Let analyze the target image creation part
|
||||||
|
if os.path.isfile('build_log_{}/{}.log'.format(self.testCase_id,image)):
|
||||||
|
errorandwarnings = {}
|
||||||
|
with open('build_log_{}/{}.log'.format(self.testCase_id,image), mode='r') as inputfile:
|
||||||
|
startOfTargetImageCreation = False
|
||||||
|
buildStatus = False
|
||||||
|
for line in inputfile:
|
||||||
|
result = re.search('FROM .* [aA][sS] ' + image + '$', str(line))
|
||||||
|
if result is not None:
|
||||||
|
startOfTargetImageCreation = True
|
||||||
|
if startOfTargetImageCreation:
|
||||||
|
result = re.search('Successfully tagged ' + image + ':', str(line))
|
||||||
|
if result is not None:
|
||||||
|
buildStatus = True
|
||||||
|
result = re.search('COMMIT ' + image + ':', str(line))
|
||||||
|
if result is not None:
|
||||||
|
buildStatus = True
|
||||||
|
inputfile.close()
|
||||||
|
if buildStatus:
|
||||||
|
errorandwarnings['errors'] = 0
|
||||||
|
else:
|
||||||
|
errorandwarnings['errors'] = 1
|
||||||
|
errorandwarnings['warnings'] = 0
|
||||||
|
errorandwarnings['status'] = buildStatus
|
||||||
|
files['Target Image Creation'] = errorandwarnings
|
||||||
self.collectInfo[image] = files
|
self.collectInfo[image] = files
|
||||||
|
|
||||||
if status:
|
if status:
|
||||||
|
|||||||
@@ -0,0 +1,292 @@
|
|||||||
|
#/*
|
||||||
|
# * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
|
||||||
|
# * contributor license agreements. See the NOTICE file distributed with
|
||||||
|
# * this work for additional information regarding copyright ownership.
|
||||||
|
# * The OpenAirInterface Software Alliance licenses this file to You under
|
||||||
|
# * the OAI Public License, Version 1.1 (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.openairinterface.org/?page_id=698
|
||||||
|
# *
|
||||||
|
# * 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.
|
||||||
|
# *-------------------------------------------------------------------------------
|
||||||
|
# * For more information about the OpenAirInterface (OAI) Software Alliance:
|
||||||
|
# * contact@openairinterface.org
|
||||||
|
# */
|
||||||
|
#---------------------------------------------------------------------
|
||||||
|
# Python for CI of OAI-eNB + COTS-UE
|
||||||
|
#
|
||||||
|
# Required Python Version
|
||||||
|
# Python 3.x
|
||||||
|
#
|
||||||
|
# Required Python Package
|
||||||
|
# pexpect
|
||||||
|
#---------------------------------------------------------------------
|
||||||
|
|
||||||
|
#-----------------------------------------------------------
|
||||||
|
# Import
|
||||||
|
#-----------------------------------------------------------
|
||||||
|
import logging
|
||||||
|
import sshconnection as SSH
|
||||||
|
import html
|
||||||
|
import os
|
||||||
|
import re
|
||||||
|
import time
|
||||||
|
import sys
|
||||||
|
import constants as CONST
|
||||||
|
import helpreadme as HELP
|
||||||
|
|
||||||
|
class PhySim:
|
||||||
|
def __init__(self):
|
||||||
|
self.eNBIpAddr = ""
|
||||||
|
self.eNBUserName = ""
|
||||||
|
self.eNBPassword = ""
|
||||||
|
self.OCUserName = ""
|
||||||
|
self.OCPassword = ""
|
||||||
|
self.OCProjectName = ""
|
||||||
|
self.eNBSourceCodePath = ""
|
||||||
|
self.ranRepository = ""
|
||||||
|
self.ranBranch = ""
|
||||||
|
self.ranCommitID= ""
|
||||||
|
self.ranAllowMerge= False
|
||||||
|
self.ranTargetBranch= ""
|
||||||
|
self.testResult = {}
|
||||||
|
self.testCount = [0,0,0]
|
||||||
|
self.testSummary = {}
|
||||||
|
self.testStatus = False
|
||||||
|
|
||||||
|
#-----------------$
|
||||||
|
#PUBLIC Methods$
|
||||||
|
#-----------------$
|
||||||
|
|
||||||
|
def Deploy_PhySim(self, HTML):
|
||||||
|
if self.ranRepository == '' or self.ranBranch == '' or self.ranCommitID == '':
|
||||||
|
HELP.GenericHelp(CONST.Version)
|
||||||
|
sys.exit('Insufficient Parameter')
|
||||||
|
lIpAddr = self.eNBIPAddress
|
||||||
|
lUserName = self.eNBUserName
|
||||||
|
lPassWord = self.eNBPassword
|
||||||
|
lSourcePath = self.eNBSourceCodePath
|
||||||
|
ocUserName = self.OCUserName
|
||||||
|
ocPassword = self.OCPassword
|
||||||
|
ocProjectName = self.OCProjectName
|
||||||
|
|
||||||
|
if lIpAddr == '' or lUserName == '' or lPassWord == '' or lSourcePath == '' or ocUserName == '' or ocPassword == '' or ocProjectName == '':
|
||||||
|
HELP.GenericHelp(CONST.Version)
|
||||||
|
sys.exit('Insufficient Parameter')
|
||||||
|
logging.debug('Building on server: ' + lIpAddr)
|
||||||
|
mySSH = SSH.SSHConnection()
|
||||||
|
mySSH.open(lIpAddr, lUserName, lPassWord)
|
||||||
|
|
||||||
|
self.testCase_id = HTML.testCase_id
|
||||||
|
|
||||||
|
# on RedHat/CentOS .git extension is mandatory
|
||||||
|
result = re.search('([a-zA-Z0-9\:\-\.\/])+\.git', self.ranRepository)
|
||||||
|
if result is not None:
|
||||||
|
full_ran_repo_name = self.ranRepository
|
||||||
|
else:
|
||||||
|
full_ran_repo_name = self.ranRepository + '.git'
|
||||||
|
mySSH.command('mkdir -p ' + lSourcePath, '\$', 5)
|
||||||
|
mySSH.command('cd ' + lSourcePath, '\$', 5)
|
||||||
|
mySSH.command('if [ ! -e .git ]; then stdbuf -o0 git clone ' + full_ran_repo_name + ' .; else stdbuf -o0 git fetch --prune; fi', '\$', 600)
|
||||||
|
# Raphael: here add a check if git clone or git fetch went smoothly
|
||||||
|
mySSH.command('git config user.email "jenkins@openairinterface.org"', '\$', 5)
|
||||||
|
mySSH.command('git config user.name "OAI Jenkins"', '\$', 5)
|
||||||
|
|
||||||
|
mySSH.command('echo ' + lPassWord + ' | sudo -S git clean -x -d -ff', '\$', 30)
|
||||||
|
mySSH.command('mkdir -p cmake_targets/log', '\$', 5)
|
||||||
|
# if the commit ID is provided use it to point to it
|
||||||
|
if self.ranCommitID != '':
|
||||||
|
mySSH.command('git checkout -f ' + self.ranCommitID, '\$', 5)
|
||||||
|
if self.ranAllowMerge:
|
||||||
|
imageTag = "ci-temp"
|
||||||
|
else:
|
||||||
|
imageTag = "develop"
|
||||||
|
# Check if image is exist on the Red Hat server, before pushing it to OC cluster
|
||||||
|
mySSH.command("sudo podman image inspect --format='Size = {{.Size}} bytes' oai-physim:" + imageTag, '\$', 60)
|
||||||
|
if mySSH.getBefore().count('no such image') != 0:
|
||||||
|
logging.error('\u001B[1m No such image oai-physim\u001B[0m')
|
||||||
|
mySSH.close()
|
||||||
|
sys.exit(-1)
|
||||||
|
else:
|
||||||
|
result = re.search('Size *= *(?P<size>[0-9\-]+) *bytes', mySSH.getBefore())
|
||||||
|
if result is not None:
|
||||||
|
imageSize = float(result.group('size'))
|
||||||
|
imageSize = imageSize / 1000
|
||||||
|
if imageSize < 1000:
|
||||||
|
logging.debug('\u001B[1m oai-physim size is ' + ('%.0f' % imageSize) + ' kbytes\u001B[0m')
|
||||||
|
else:
|
||||||
|
imageSize = imageSize / 1000
|
||||||
|
if imageSize < 1000:
|
||||||
|
logging.debug('\u001B[1m oai-physim size is ' + ('%.0f' % imageSize) + ' Mbytes\u001B[0m')
|
||||||
|
else:
|
||||||
|
imageSize = imageSize / 1000
|
||||||
|
logging.debug('\u001B[1m oai-physim is ' + ('%.3f' % imageSize) + ' Gbytes\u001B[0m')
|
||||||
|
else:
|
||||||
|
logging.debug('oai-physim size is unknown')
|
||||||
|
|
||||||
|
# logging to OC Cluster and then switch to corresponding project
|
||||||
|
mySSH.command(f'oc login -u {ocUserName} -p {ocPassword}', '\$', 6)
|
||||||
|
if mySSH.getBefore().count('Login successful.') == 0:
|
||||||
|
logging.error('\u001B[1m OC Cluster Login Failed\u001B[0m')
|
||||||
|
mySSH.close()
|
||||||
|
sys.exit(-1)
|
||||||
|
else:
|
||||||
|
logging.debug('\u001B[1m Login to OC Cluster Successfully\u001B[0m')
|
||||||
|
mySSH.command(f'oc project {ocProjectName}', '\$', 6)
|
||||||
|
if mySSH.getBefore().count(f'Already on project "{ocProjectName}"') == 0 and mySSH.getBefore().count(f'Now using project "{self.OCProjectName}"') == 0:
|
||||||
|
logging.error(f'\u001B[1m Unable to access OC project {ocProjectName}\u001B[0m')
|
||||||
|
mySSH.close()
|
||||||
|
sys.exit(-1)
|
||||||
|
else:
|
||||||
|
logging.debug(f'\u001B[1m Now using project {ocProjectName}\u001B[0m')
|
||||||
|
|
||||||
|
# Tag the image and push to the OC cluster
|
||||||
|
mySSH.command('oc whoami -t | sudo podman login -u ' + ocUserName + ' --password-stdin https://default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/ --tls-verify=false', '\$', 6)
|
||||||
|
if mySSH.getBefore().count('Login Succeeded!') == 0:
|
||||||
|
logging.error('\u001B[1m Podman Login to OC Cluster Registry Failed\u001B[0m')
|
||||||
|
mySSH.close()
|
||||||
|
sys.exit(-1)
|
||||||
|
else:
|
||||||
|
logging.debug('\u001B[1m Podman Login to OC Cluster Registry Successfully\u001B[0m')
|
||||||
|
mySSH.command('oc create -f openshift/oai-physim-image-stream.yml', '\$', 6)
|
||||||
|
if mySSH.getBefore().count('(AlreadyExists):') == 0 and mySSH.getBefore().count('created') == 0:
|
||||||
|
logging.error(f'\u001B[1m Image Stream "oai-physim" Creation Failed on OC Cluster {ocProjectName}\u001B[0m')
|
||||||
|
mySSH.close()
|
||||||
|
sys.exit(-1)
|
||||||
|
else:
|
||||||
|
logging.debug(f'\u001B[1m Image Stream "oai-physim" created on OC project {ocProjectName}\u001B[0m')
|
||||||
|
mySSH.command(f'sudo podman tag oai-physim:{imageTag} default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/{self.OCProjectName}/oai-physim:{imageTag}', '\$', 6)
|
||||||
|
mySSH.command(f'sudo podman push default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/{self.OCProjectName}/oai-physim:{imageTag} --tls-verify=false', '\$', 30)
|
||||||
|
if mySSH.getBefore().count('Storing signatures') == 0:
|
||||||
|
logging.error('\u001B[1m Image "oai-physim" push to OC Cluster Registry Failed\u001B[0m')
|
||||||
|
mySSH.close()
|
||||||
|
sys.exit(-1)
|
||||||
|
else:
|
||||||
|
logging.debug('\u001B[1m Image "oai-physim" push to OC Cluster Registry Successfully\u001B[0m')
|
||||||
|
|
||||||
|
# Using helm charts deployment
|
||||||
|
mySSH.command(f'sed -i -e "s#TAG#{imageTag}#g" ./charts/physims/values.yaml', '\$', 6)
|
||||||
|
mySSH.command('helm install physim ./charts/physims/ | tee -a cmake_targets/log/physim_helm_summary.txt 2>&1', '\$', 6)
|
||||||
|
if mySSH.getBefore().count('STATUS: deployed') == 0:
|
||||||
|
logging.error('\u001B[1m Deploying PhySim Failed using helm chart on OC Cluster\u001B[0m')
|
||||||
|
mySSH.command('helm uninstall physim >> cmake_targets/log/physim_helm_summary.txt 2>&1', '\$', 6)
|
||||||
|
mySSH.close()
|
||||||
|
self.AnalyzeLogFile_phySim(HTML)
|
||||||
|
sys.exit(-1)
|
||||||
|
else:
|
||||||
|
logging.debug('\u001B[1m Deployed PhySim Successfully using helm chart\u001B[0m')
|
||||||
|
isRunning = False
|
||||||
|
count = 0
|
||||||
|
while(count < 2 and isRunning == False):
|
||||||
|
time.sleep(60)
|
||||||
|
mySSH.command('oc get pods -o wide -l app.kubernetes.io/instance=physim | tee -a cmake_targets/log/physim_pods_summary.txt', '\$', 6, resync=True)
|
||||||
|
if mySSH.getBefore().count('Running') == 12:
|
||||||
|
logging.debug('\u001B[1m Running the physim test Scenarios\u001B[0m')
|
||||||
|
isRunning = True
|
||||||
|
podNames = re.findall('oai-[\S\d\w]+', mySSH.getBefore())
|
||||||
|
count +=1
|
||||||
|
if isRunning == False:
|
||||||
|
logging.error('\u001B[1m Some PODS Running FAILED \u001B[0m')
|
||||||
|
mySSH.command('oc get pods -l app.kubernetes.io/instance=physim 2>&1 | tee -a cmake_targets/log/physim_pods_summary.txt', '\$', 6)
|
||||||
|
mySSH.command('helm uninstall physim >> cmake_targets/log/physim_helm_summary.txt 2>&1', '\$', 6)
|
||||||
|
self.AnalyzeLogFile_phySim(HTML)
|
||||||
|
sys.exit(-1)
|
||||||
|
# Waiting to complete the running test
|
||||||
|
count = 0
|
||||||
|
isFinished = False
|
||||||
|
# doing a deep copy!
|
||||||
|
tmpPodNames = podNames.copy()
|
||||||
|
while(count < 28 and isFinished == False):
|
||||||
|
time.sleep(58)
|
||||||
|
for podName in tmpPodNames:
|
||||||
|
mySSH.command(f'oc logs --tail=1 {podName} 2>&1', '\$', 6, silent=True, resync=True)
|
||||||
|
time.sleep(2)
|
||||||
|
if mySSH.getBefore().count('FINISHED') != 0:
|
||||||
|
logging.debug(podName + ' is finished')
|
||||||
|
tmpPodNames.remove(podName)
|
||||||
|
if not tmpPodNames:
|
||||||
|
isFinished = True
|
||||||
|
count += 1
|
||||||
|
if isFinished:
|
||||||
|
logging.debug('\u001B[1m PhySim test is Complete\u001B[0m')
|
||||||
|
|
||||||
|
# Getting the logs of each executables running in individual pods
|
||||||
|
for podName in podNames:
|
||||||
|
mySSH.command(f'oc logs {podName} >> cmake_targets/log/physim_test.txt 2>&1', '\$', 15, resync=True)
|
||||||
|
time.sleep(30)
|
||||||
|
|
||||||
|
# UnDeploy the physical simulator pods
|
||||||
|
mySSH.command('helm uninstall physim | tee -a cmake_targets/log/physim_helm_summary.txt 2>&1', '\$', 6)
|
||||||
|
isFinished1 = False
|
||||||
|
while(isFinished1 == False):
|
||||||
|
time.sleep(20)
|
||||||
|
mySSH.command('oc get pods -l app.kubernetes.io/instance=physim', '\$', 6, resync=True)
|
||||||
|
if re.search('No resources found', mySSH.getBefore()):
|
||||||
|
isFinished1 = True
|
||||||
|
if isFinished1 == True:
|
||||||
|
logging.debug('\u001B[1m UnDeployed PhySim Successfully on OC Cluster\u001B[0m')
|
||||||
|
mySSH.command(f'sudo podman rmi default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/{self.OCProjectName}/oai-physim:{imageTag}', '\$', 6)
|
||||||
|
mySSH.command('oc delete is oai-physim', '\$', 6)
|
||||||
|
logging.debug('\u001B[1m Deleted the Image and ImageStream\u001B[0m')
|
||||||
|
mySSH.command('oc logout', '\$', 6)
|
||||||
|
mySSH.close()
|
||||||
|
self.AnalyzeLogFile_phySim(HTML)
|
||||||
|
if self.testStatus == False:
|
||||||
|
sys.exit(-1)
|
||||||
|
|
||||||
|
def AnalyzeLogFile_phySim(self, HTML):
|
||||||
|
lIpAddr = self.eNBIPAddress
|
||||||
|
lUserName = self.eNBUserName
|
||||||
|
lPassWord = self.eNBPassword
|
||||||
|
lSourcePath = self.eNBSourceCodePath
|
||||||
|
mySSH = SSH.SSHConnection()
|
||||||
|
mySSH.open(lIpAddr, lUserName, lPassWord)
|
||||||
|
mySSH.command('cd ' + lSourcePath, '\$', 5)
|
||||||
|
mySSH.command('cd ' + lSourcePath + '/cmake_targets', '\$', 5)
|
||||||
|
mySSH.command('mkdir -p physim_test_log_' + self.testCase_id, '\$', 5)
|
||||||
|
mySSH.command('cp log/physim_* ' + 'physim_test_log_' + self.testCase_id, '\$', 5)
|
||||||
|
if not os.path.exists(f'./physim_test_logs_{self.testCase_id}'):
|
||||||
|
os.mkdir(f'./physim_test_logs_{self.testCase_id}')
|
||||||
|
mySSH.copyin(lIpAddr, lUserName, lPassWord, lSourcePath + '/cmake_targets/physim_test_log_' + self.testCase_id + '/*', './physim_test_logs_' + self.testCase_id)
|
||||||
|
mySSH.command('rm -rf ./physim_test_log_'+ self.testCase_id, '\$', 5)
|
||||||
|
mySSH.command('oc logout', '\$', 6)
|
||||||
|
mySSH.close()
|
||||||
|
# physim test log analysis
|
||||||
|
nextt = 0
|
||||||
|
if (os.path.isfile(f'./physim_test_logs_{self.testCase_id}/physim_test.txt')):
|
||||||
|
with open(f'./physim_test_logs_{self.testCase_id}/physim_test.txt', 'r') as logfile:
|
||||||
|
for line in logfile:
|
||||||
|
if re.search('execution 015', str(line)) or re.search('Bypassing compilation', str(line)):
|
||||||
|
nextt = 1
|
||||||
|
elif nextt == 1:
|
||||||
|
if not re.search('Test Results', str(line)):
|
||||||
|
nextt = 0
|
||||||
|
ret2 = re.search('T[^\n]*', str(line))
|
||||||
|
if ret2 is not None:
|
||||||
|
ret3 = ret2.group()
|
||||||
|
ret3 = ret3.replace("[00m", "")
|
||||||
|
if re.search('execution 015', str(line)):
|
||||||
|
self.testCount[0] += 1
|
||||||
|
testName = line.split()
|
||||||
|
ret1 = re.search('Result = PASS', str(line))
|
||||||
|
if ret1 is not None:
|
||||||
|
self.testResult[testName[1]] = [ret3, 'PASS']
|
||||||
|
self.testCount[1] += 1
|
||||||
|
else:
|
||||||
|
self.testResult[testName[1]] = [ret3, 'FAIL']
|
||||||
|
self.testCount[2] += 1
|
||||||
|
self.testSummary['Nbtests'] = self.testCount[0]
|
||||||
|
self.testSummary['Nbpass'] = self.testCount[1]
|
||||||
|
self.testSummary['Nbfail'] = self.testCount[2]
|
||||||
|
if self.testSummary['Nbfail'] == 0:
|
||||||
|
self.testStatus = True
|
||||||
|
HTML.CreateHtmlTestRow('N/A', 'OK', CONST.ALL_PROCESSES_OK)
|
||||||
|
HTML.CreateHtmlTestRowPhySimTestResult(self.testSummary,self.testResult)
|
||||||
|
logging.info('\u001B[1m Physical Simulator Pass\u001B[0m')
|
||||||
|
return 0
|
||||||
@@ -66,17 +66,7 @@ gNBs =
|
|||||||
|
|
||||||
initialDLBWPk0_1 = 0; #for mixed slot
|
initialDLBWPk0_1 = 0; #for mixed slot
|
||||||
initialDLBWPmappingType_1 = 0;
|
initialDLBWPmappingType_1 = 0;
|
||||||
initialDLBWPstartSymbolAndLength_1 = 53; #this is SS=1,L=5
|
initialDLBWPstartSymbolAndLength_1 = 57; #this is SS=1,L=5
|
||||||
|
|
||||||
initialDLBWPk0_2 = 0;
|
|
||||||
initialDLBWPmappingType_2 = 0;
|
|
||||||
#this is SS=1,L=12
|
|
||||||
initialDLBWPstartSymbolAndLength_2 = 54;
|
|
||||||
|
|
||||||
initialDLBWPk0_3 = 0;
|
|
||||||
initialDLBWPmappingType_3 = 0;
|
|
||||||
#this is SS=1,L=4 //5 (4 is for 43, 5 is for 57)
|
|
||||||
initialDLBWPstartSymbolAndLength_3 = 57; //43; //57;
|
|
||||||
|
|
||||||
#uplinkConfigCommon
|
#uplinkConfigCommon
|
||||||
#frequencyInfoUL
|
#frequencyInfoUL
|
||||||
@@ -102,6 +92,8 @@ gNBs =
|
|||||||
prach_msg1_FDM = 0;
|
prach_msg1_FDM = 0;
|
||||||
prach_msg1_FrequencyStart = 74;
|
prach_msg1_FrequencyStart = 74;
|
||||||
zeroCorrelationZoneConfig = 13;
|
zeroCorrelationZoneConfig = 13;
|
||||||
|
#preambleReceivedTargetPower = -118;
|
||||||
|
#preambleReceivedTargetPower = -104;
|
||||||
preambleReceivedTargetPower = -108;
|
preambleReceivedTargetPower = -108;
|
||||||
#preamblTransMax (0...10) = (3,4,5,6,7,8,10,20,50,100,200)
|
#preamblTransMax (0...10) = (3,4,5,6,7,8,10,20,50,100,200)
|
||||||
preambleTransMax = 6;
|
preambleTransMax = 6;
|
||||||
|
|||||||
@@ -230,6 +230,7 @@ MACRLCs = (
|
|||||||
num_cc = 1;
|
num_cc = 1;
|
||||||
tr_s_preference = "local_L1";
|
tr_s_preference = "local_L1";
|
||||||
tr_n_preference = "local_RRC";
|
tr_n_preference = "local_RRC";
|
||||||
|
ulsch_max_slots_inactivity = 1;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@@ -211,6 +211,7 @@ MACRLCs = (
|
|||||||
num_cc = 1;
|
num_cc = 1;
|
||||||
tr_s_preference = "local_L1";
|
tr_s_preference = "local_L1";
|
||||||
tr_n_preference = "local_RRC";
|
tr_n_preference = "local_RRC";
|
||||||
|
ulsch_max_slots_inactivity = 1;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -231,7 +232,7 @@ RUs = (
|
|||||||
att_rx = 0;
|
att_rx = 0;
|
||||||
bands = [7];
|
bands = [7];
|
||||||
max_pdschReferenceSignalPower = -27;
|
max_pdschReferenceSignalPower = -27;
|
||||||
max_rxgain = 75;
|
max_rxgain = 50;
|
||||||
eNB_instances = [0];
|
eNB_instances = [0];
|
||||||
## beamforming 1x2 matrix: 1 layer x 2 antennas
|
## beamforming 1x2 matrix: 1 layer x 2 antennas
|
||||||
bf_weights = [0x00007fff, 0x0000];
|
bf_weights = [0x00007fff, 0x0000];
|
||||||
|
|||||||
@@ -87,7 +87,7 @@ function create_vm {
|
|||||||
echo "VM_CPU = $VM_CPU"
|
echo "VM_CPU = $VM_CPU"
|
||||||
echo "VM_DISK = $VM_DISK GBytes"
|
echo "VM_DISK = $VM_DISK GBytes"
|
||||||
|
|
||||||
if [[ "$VM_NAME" == *"-enb-usrp"* ]] || [[ "$VM_NAME" == *"-cppcheck"* ]]
|
if [[ "$VM_NAME" == *"-enb-usrp"* ]] || [[ "$VM_NAME" == *"-cppcheck"* ]] || [[ "$VM_NAME" == *"-phy-sim"* ]]
|
||||||
then
|
then
|
||||||
echo "This VM type is no longer supported in the pipeline framework"
|
echo "This VM type is no longer supported in the pipeline framework"
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -0,0 +1,33 @@
|
|||||||
|
#this is a configuration file
|
||||||
|
#used to build real time processing statistics
|
||||||
|
#for 5G NR phy test (gNB terminate)
|
||||||
|
Title : Processing Time (us)
|
||||||
|
ColNames :
|
||||||
|
- Metric
|
||||||
|
- Average
|
||||||
|
- Max
|
||||||
|
- Average vs Reference Deviation (Reference Value ; Acceptability Threshold)
|
||||||
|
Ref :
|
||||||
|
feprx : 60.0
|
||||||
|
feptx_prec : 8.0
|
||||||
|
feptx_ofdm : 85.0
|
||||||
|
feptx_total : 75.0
|
||||||
|
L1 Tx processing : 300.0
|
||||||
|
DLSCH encoding : 230.0
|
||||||
|
L1 Rx processing : 175.0
|
||||||
|
PUSCH inner-receiver : 100.0
|
||||||
|
PUSCH decoding : 140.0
|
||||||
|
DL & UL scheduling timing stats : 15.0
|
||||||
|
UL Indication : 20.0
|
||||||
|
Threshold :
|
||||||
|
feprx : 1.25
|
||||||
|
feptx_prec : 1.25
|
||||||
|
feptx_ofdm : 1.25
|
||||||
|
feptx_total : 1.25
|
||||||
|
L1 Tx processing : 1.25
|
||||||
|
DLSCH encoding : 1.25
|
||||||
|
L1 Rx processing : 1.25
|
||||||
|
PUSCH inner-receiver : 1.25
|
||||||
|
PUSCH decoding : 1.25
|
||||||
|
DL & UL scheduling timing stats : 1.25
|
||||||
|
UL Indication : 1.25
|
||||||
+92
-2
@@ -412,7 +412,12 @@ class HTMLManagement():
|
|||||||
for image in collectInfo:
|
for image in collectInfo:
|
||||||
files = collectInfo[image]
|
files = collectInfo[image]
|
||||||
# TabHeader for image logs on built shared and target images
|
# TabHeader for image logs on built shared and target images
|
||||||
self.htmlFile.write(' <tr bgcolor = "#F0F0F0" >\n')
|
if allImagesSize[image].count('unknown') > 0:
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "orange" >\n')
|
||||||
|
elif allImagesSize[image].count('Build Failed') > 0:
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "red" >\n')
|
||||||
|
else:
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "#F0F0F0" >\n')
|
||||||
self.htmlFile.write(' <td colspan=' + str(5+self.htmlUEConnected) + '><b> ---- ' + image + ' IMAGE STATUS ----> Size ' + allImagesSize[image] + ' </b></td>\n')
|
self.htmlFile.write(' <td colspan=' + str(5+self.htmlUEConnected) + '><b> ---- ' + image + ' IMAGE STATUS ----> Size ' + allImagesSize[image] + ' </b></td>\n')
|
||||||
self.htmlFile.write(' </tr>\n')
|
self.htmlFile.write(' </tr>\n')
|
||||||
self.htmlFile.write(' <tr bgcolor = "#33CCFF" >\n')
|
self.htmlFile.write(' <tr bgcolor = "#33CCFF" >\n')
|
||||||
@@ -431,7 +436,9 @@ class HTMLManagement():
|
|||||||
self.htmlFile.write(' <td bgcolor = "green" >' + str(parameters['errors']) + '</td>\n')
|
self.htmlFile.write(' <td bgcolor = "green" >' + str(parameters['errors']) + '</td>\n')
|
||||||
else:
|
else:
|
||||||
self.htmlFile.write(' <td bgcolor = "red" >' + str(parameters['errors']) + '</td>\n')
|
self.htmlFile.write(' <td bgcolor = "red" >' + str(parameters['errors']) + '</td>\n')
|
||||||
if (parameters['warnings'] == 0):
|
if (parameters['errors'] > 0):
|
||||||
|
self.htmlFile.write(' <td bgcolor = "red" >' + str(parameters['warnings']) + '</td>\n')
|
||||||
|
elif (parameters['warnings'] == 0):
|
||||||
self.htmlFile.write(' <td bgcolor = "green" >' + str(parameters['warnings']) + '</td>\n')
|
self.htmlFile.write(' <td bgcolor = "green" >' + str(parameters['warnings']) + '</td>\n')
|
||||||
elif ((parameters['warnings'] > 0) and (parameters['warnings'] <= 20)):
|
elif ((parameters['warnings'] > 0) and (parameters['warnings'] <= 20)):
|
||||||
self.htmlFile.write(' <td bgcolor = "orange" >' + str(parameters['warnings']) + '</td>\n')
|
self.htmlFile.write(' <td bgcolor = "orange" >' + str(parameters['warnings']) + '</td>\n')
|
||||||
@@ -446,6 +453,37 @@ class HTMLManagement():
|
|||||||
self.htmlFile.write(' </tr>\n')
|
self.htmlFile.write(' </tr>\n')
|
||||||
self.htmlFile.close()
|
self.htmlFile.close()
|
||||||
|
|
||||||
|
#for the moment it is limited to 4 columns, to be made generic later
|
||||||
|
def CreateHtmlDataLogTable(self, DataLog):
|
||||||
|
if (self.htmlFooterCreated or (not self.htmlHeaderCreated)):
|
||||||
|
return
|
||||||
|
self.htmlFile = open('test_results.html', 'a')
|
||||||
|
|
||||||
|
# TabHeader
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "#F0F0F0" >\n')
|
||||||
|
self.htmlFile.write(' <td colspan=' + str(5+self.htmlUEConnected) + '><b> ---- ' + DataLog['Title'] + ' ---- </b></td>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "#33CCFF" >\n')
|
||||||
|
self.htmlFile.write(' <th colspan="3">'+ DataLog['ColNames'][0] +'</th>\n')
|
||||||
|
self.htmlFile.write(' <th>' + DataLog['ColNames'][1] + '</th>\n')
|
||||||
|
self.htmlFile.write(' <th>' + DataLog['ColNames'][2] + '</th>\n')
|
||||||
|
self.htmlFile.write(' <th colspan=' + str(1+self.htmlUEConnected) + '>'+ DataLog['ColNames'][3] +'</th>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
|
||||||
|
for k in DataLog['Data']:
|
||||||
|
# TestRow
|
||||||
|
self.htmlFile.write(' <tr>\n')
|
||||||
|
self.htmlFile.write(' <td colspan="3" bgcolor = "lightcyan" >' + k + ' </td>\n')
|
||||||
|
self.htmlFile.write(' <td bgcolor = "lightcyan" >' + DataLog['Data'][k][0] + ' </td>\n')
|
||||||
|
self.htmlFile.write(' <td bgcolor = "lightcyan" >' + DataLog['Data'][k][1] + ' </td>\n')
|
||||||
|
if float(DataLog['Data'][k][2])> DataLog['Threshold'][k]:
|
||||||
|
self.htmlFile.write(' <th bgcolor = "red" >' + DataLog['Data'][k][2] + ' (Ref = ' + str(DataLog['Ref'][k]) + ' ; Thres = ' +str(DataLog['Threshold'][k])+') ' + '</th>\n')
|
||||||
|
else:
|
||||||
|
self.htmlFile.write(' <th bgcolor = "green" ><font color="white">' + DataLog['Data'][k][2] + ' (Ref = ' + str(DataLog['Ref'][k]) + ' ; Thres = ' +str(DataLog['Threshold'][k])+') ' + '</th>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
self.htmlFile.close()
|
||||||
|
|
||||||
|
|
||||||
def CreateHtmlTestRowQueue(self, options, status, ue_status, ue_queue):
|
def CreateHtmlTestRowQueue(self, options, status, ue_status, ue_queue):
|
||||||
if ((not self.htmlFooterCreated) and (self.htmlHeaderCreated)):
|
if ((not self.htmlFooterCreated) and (self.htmlHeaderCreated)):
|
||||||
self.htmlFile = open('test_results.html', 'a')
|
self.htmlFile = open('test_results.html', 'a')
|
||||||
@@ -563,4 +601,56 @@ class HTMLManagement():
|
|||||||
self.htmlFile.write(' </tr>\n')
|
self.htmlFile.write(' </tr>\n')
|
||||||
vId += 1
|
vId += 1
|
||||||
|
|
||||||
|
def CreateHtmlTestRowPhySimTestResult(self, testSummary, testResult):
|
||||||
|
if (self.htmlFooterCreated or (not self.htmlHeaderCreated)):
|
||||||
|
return
|
||||||
|
self.htmlFile = open('test_results.html', 'a')
|
||||||
|
if bool(testResult) == False and bool(testSummary) == False:
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "red" >\n')
|
||||||
|
self.htmlFile.write(' <td colspan=' + str(5+self.htmlUEConnected) + '><b> ----PHYSIM TESTING FAILED - Unable to recover the test logs ---- </b></td>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
else:
|
||||||
|
# Tab header
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "#F0F0F0" >\n')
|
||||||
|
self.htmlFile.write(' <td colspan=' + str(5+self.htmlUEConnected) + '><b> ---- PHYSIM TEST SUMMARY---- </b></td>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "#33CCFF" >\n')
|
||||||
|
self.htmlFile.write(' <th colspan="2">LogFile Name</th>\n')
|
||||||
|
self.htmlFile.write(' <th colspan="2">Nb Tests</th>\n')
|
||||||
|
self.htmlFile.write(' <th>Nb Failure</th>\n')
|
||||||
|
self.htmlFile.write(' <th>Nb Pass</th>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
self.htmlFile.write(' <tr>\n')
|
||||||
|
self.htmlFile.write(' <td colspan="2" bgcolor = "lightcyan" > physim_test.txt </td>\n')
|
||||||
|
self.htmlFile.write(' <td colspan="2" bgcolor = "lightcyan" >' + str(testSummary['Nbtests']) + ' </td>\n')
|
||||||
|
if testSummary['Nbfail'] == 0:
|
||||||
|
self.htmlFile.write(' <td bgcolor = "lightcyan" >' + str(testSummary['Nbfail']) + ' </td>\n')
|
||||||
|
else:
|
||||||
|
self.htmlFile.write(' <td bgcolor = "red" >' + str(testSummary['Nbfail']) + ' </td>\n')
|
||||||
|
self.htmlFile.write(' <td gcolor = "lightcyan" >' + str(testSummary['Nbpass']) + ' </td>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "#F0F0F0" >\n')
|
||||||
|
self.htmlFile.write(' <td colspan=' + str(5+self.htmlUEConnected) + '><b> ---- PHYSIM TEST DETAIL INFO---- </b></td>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "#33CCFF" >\n')
|
||||||
|
self.htmlFile.write(' <th colspan="2">Test Name</th>\n')
|
||||||
|
self.htmlFile.write(' <th colspan="2">Test Description</th>\n')
|
||||||
|
self.htmlFile.write(' <th colspan=' + str(1+self.htmlUEConnected) + '>Result</th>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
y = ''
|
||||||
|
for key, value in testResult.items():
|
||||||
|
x = key.split(".")
|
||||||
|
if x[0] != y:
|
||||||
|
self.htmlFile.write(' <tr bgcolor = "lightgreen" >\n')
|
||||||
|
self.htmlFile.write(' <td style="text-align: center;" colspan=' + str(5+self.htmlUEConnected) + '><b>"' + x[0] + '" series </b></td>\n')
|
||||||
|
self.htmlFile.write(' </tr>\n')
|
||||||
|
y = x[0]
|
||||||
|
self.htmlFile.write(' <tr>\n')
|
||||||
|
self.htmlFile.write(' <td colspan="2" bgcolor = "lightcyan" >' + key + ' </td>\n')
|
||||||
|
self.htmlFile.write(' <td colspan="2" bgcolor = "lightcyan" >' + value[0] + '</td>\n')
|
||||||
|
if 'PASS' in value:
|
||||||
|
self.htmlFile.write(' <td colspan=' + str(1+self.htmlUEConnected) + ' bgcolor = "green" >' + value[1] + '</td>\n')
|
||||||
|
else:
|
||||||
|
self.htmlFile.write(' <td colspan=' + str(1+self.htmlUEConnected) + ' bgcolor = "red" >' + value[1] + '</td>\n')
|
||||||
|
|
||||||
self.htmlFile.close()
|
self.htmlFile.close()
|
||||||
|
|||||||
+5
-2
@@ -43,7 +43,7 @@ import cls_physim #class PhySim for physical simulators build and
|
|||||||
import cls_cots_ue #class CotsUe for Airplane mode control
|
import cls_cots_ue #class CotsUe for Airplane mode control
|
||||||
import cls_containerize #class Containerize for all container-based operations on RAN/UE objects
|
import cls_containerize #class Containerize for all container-based operations on RAN/UE objects
|
||||||
import cls_static_code_analysis #class for static code analysis
|
import cls_static_code_analysis #class for static code analysis
|
||||||
|
import cls_physim1 #class PhySim for physical simulators deploy and run
|
||||||
|
|
||||||
import sshconnection
|
import sshconnection
|
||||||
import epc
|
import epc
|
||||||
@@ -380,6 +380,7 @@ RAN = ran.RANManagement()
|
|||||||
HTML = html.HTMLManagement()
|
HTML = html.HTMLManagement()
|
||||||
CONTAINERS = cls_containerize.Containerize()
|
CONTAINERS = cls_containerize.Containerize()
|
||||||
SCA = cls_static_code_analysis.StaticCodeAnalysis()
|
SCA = cls_static_code_analysis.StaticCodeAnalysis()
|
||||||
|
PHYSIM = cls_physim1.PhySim()
|
||||||
|
|
||||||
ldpc=cls_physim.PhySim() #create an instance for LDPC test using GPU or CPU build
|
ldpc=cls_physim.PhySim() #create an instance for LDPC test using GPU or CPU build
|
||||||
|
|
||||||
@@ -390,7 +391,7 @@ ldpc=cls_physim.PhySim() #create an instance for LDPC test using GPU or CPU b
|
|||||||
#-----------------------------------------------------------
|
#-----------------------------------------------------------
|
||||||
|
|
||||||
import args_parse
|
import args_parse
|
||||||
py_param_file_present, py_params, mode = args_parse.ArgsParse(sys.argv,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA)
|
py_param_file_present, py_params, mode = args_parse.ArgsParse(sys.argv,CiTestObj,RAN,HTML,EPC,ldpc,CONTAINERS,HELP,SCA,PHYSIM)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -745,6 +746,8 @@ elif re.match('^TesteNB$', mode, re.IGNORECASE) or re.match('^TestUE$', mode, re
|
|||||||
CONTAINERS.UndeployObject(HTML, RAN)
|
CONTAINERS.UndeployObject(HTML, RAN)
|
||||||
elif action == 'Cppcheck_Analysis':
|
elif action == 'Cppcheck_Analysis':
|
||||||
SCA.CppCheckAnalysis(HTML)
|
SCA.CppCheckAnalysis(HTML)
|
||||||
|
elif action == 'Deploy_Run_PhySim':
|
||||||
|
PHYSIM.Deploy_PhySim(HTML)
|
||||||
else:
|
else:
|
||||||
sys.exit('Invalid class (action) from xml')
|
sys.exit('Invalid class (action) from xml')
|
||||||
if not RAN.prematureExit:
|
if not RAN.prematureExit:
|
||||||
|
|||||||
+41
-11
@@ -37,6 +37,8 @@ import logging
|
|||||||
import os
|
import os
|
||||||
import time
|
import time
|
||||||
from multiprocessing import Process, Lock, SimpleQueue
|
from multiprocessing import Process, Lock, SimpleQueue
|
||||||
|
import yaml
|
||||||
|
|
||||||
|
|
||||||
#-----------------------------------------------------------
|
#-----------------------------------------------------------
|
||||||
# OAI Testing modules
|
# OAI Testing modules
|
||||||
@@ -90,6 +92,7 @@ class RANManagement():
|
|||||||
self.testCase_id = ''
|
self.testCase_id = ''
|
||||||
self.epcPcapFile = ''
|
self.epcPcapFile = ''
|
||||||
self.runtime_stats= ''
|
self.runtime_stats= ''
|
||||||
|
self.datalog_rt_stats={}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -633,6 +636,8 @@ class RANManagement():
|
|||||||
HTML.CreateHtmlTestRow(self.runtime_stats, 'OK', CONST.ALL_PROCESSES_OK)
|
HTML.CreateHtmlTestRow(self.runtime_stats, 'OK', CONST.ALL_PROCESSES_OK)
|
||||||
else:
|
else:
|
||||||
HTML.CreateHtmlTestRow(self.runtime_stats, 'OK', CONST.ALL_PROCESSES_OK)
|
HTML.CreateHtmlTestRow(self.runtime_stats, 'OK', CONST.ALL_PROCESSES_OK)
|
||||||
|
if len(self.datalog_rt_stats)!=0:
|
||||||
|
HTML.CreateHtmlDataLogTable(self.datalog_rt_stats)
|
||||||
self.eNBmbmsEnables[int(self.eNB_instance)] = False
|
self.eNBmbmsEnables[int(self.eNB_instance)] = False
|
||||||
self.eNBstatuses[int(self.eNB_instance)] = -1
|
self.eNBstatuses[int(self.eNB_instance)] = -1
|
||||||
|
|
||||||
@@ -699,6 +704,21 @@ class RANManagement():
|
|||||||
#count "problem receiving samples" msg
|
#count "problem receiving samples" msg
|
||||||
pb_receiving_samples_cnt = 0
|
pb_receiving_samples_cnt = 0
|
||||||
|
|
||||||
|
#the datalog config file has to be loaded
|
||||||
|
datalog_rt_stats_file='datalog_rt_stats.yaml'
|
||||||
|
if (os.path.isfile(datalog_rt_stats_file)):
|
||||||
|
yaml_file=datalog_rt_stats_file
|
||||||
|
elif (os.path.isfile('ci-scripts/'+datalog_rt_stats_file)):
|
||||||
|
yaml_file='ci-scripts/'+datalog_rt_stats_file
|
||||||
|
else:
|
||||||
|
logging.error("Datalog RT stats yaml file cannot be found")
|
||||||
|
sys.exit("Datalog RT stats yaml file cannot be found")
|
||||||
|
|
||||||
|
with open(yaml_file,'r') as f:
|
||||||
|
datalog_rt_stats = yaml.load(f,Loader=yaml.FullLoader)
|
||||||
|
rt_keys = datalog_rt_stats['Ref'] #we use the keys from the Ref field
|
||||||
|
|
||||||
|
|
||||||
for line in enb_log_file.readlines():
|
for line in enb_log_file.readlines():
|
||||||
# Runtime statistics
|
# Runtime statistics
|
||||||
result = re.search('Run time:' ,str(line))
|
result = re.search('Run time:' ,str(line))
|
||||||
@@ -857,21 +877,21 @@ class RANManagement():
|
|||||||
#keys below are the markers we are loooking for, loop over this keys list
|
#keys below are the markers we are loooking for, loop over this keys list
|
||||||
#everytime these markers are found in the log file, the previous ones are overwritten in the dict
|
#everytime these markers are found in the log file, the previous ones are overwritten in the dict
|
||||||
#eventually we record and print only the last occurence
|
#eventually we record and print only the last occurence
|
||||||
keys = {'UE ID','dlsch_rounds','dlsch_total_bytes','ulsch_rounds','ulsch_total_bytes_scheduled', 'scheduling timing stats'}
|
keys = {'UE ID','dlsch_rounds','dlsch_total_bytes','ulsch_rounds','ulsch_total_bytes_scheduled'}
|
||||||
for k in keys:
|
for k in keys:
|
||||||
result = re.search(k, line)
|
result = re.search(k, line)
|
||||||
if result is not None:
|
if result is not None:
|
||||||
#remove 1- all useless char before relevant info (ulsch or dlsch) 2- trailing char
|
#remove 1- all useless char before relevant info (ulsch or dlsch) 2- trailing char
|
||||||
dlsch_ulsch_stats[k]=re.sub(r'^.*\]\s+', r'' , line.rstrip())
|
dlsch_ulsch_stats[k]=re.sub(r'^.*\]\s+', r'' , line.rstrip())
|
||||||
#real time statistics
|
#real time statistics for gNB
|
||||||
#same method as above
|
for k in rt_keys:
|
||||||
keys = {'feprx','feptx_prec','feptx_ofdm','feptx_total','L1 Tx processing','DLSCH encoding','L1 Rx processing','PUSCH inner-receiver','PUSCH decoding'}
|
|
||||||
for k in keys:
|
|
||||||
result = re.search(k, line)
|
result = re.search(k, line)
|
||||||
if result is not None:
|
if result is not None:
|
||||||
#remove 1- all useless char before relevant info 2- trailing char
|
#remove 1- all useless char before relevant info 2- trailing char
|
||||||
|
line=line.replace('[0m','')
|
||||||
tmp=re.match(rf'^.*?(\b{k}\b.*)',line.rstrip()) #from python 3.6 we can use literal string interpolation for the variable k, using rf' in the regex
|
tmp=re.match(rf'^.*?(\b{k}\b.*)',line.rstrip()) #from python 3.6 we can use literal string interpolation for the variable k, using rf' in the regex
|
||||||
real_time_stats[k]=tmp.group(1)
|
real_time_stats[k]=tmp.group(1)
|
||||||
|
|
||||||
#count "problem receiving samples" msg
|
#count "problem receiving samples" msg
|
||||||
result = re.search('\[PHY\]\s+problem receiving samples', str(line))
|
result = re.search('\[PHY\]\s+problem receiving samples', str(line))
|
||||||
if result is not None:
|
if result is not None:
|
||||||
@@ -920,13 +940,23 @@ class RANManagement():
|
|||||||
logging.debug(dlsch_ulsch_stats[key])
|
logging.debug(dlsch_ulsch_stats[key])
|
||||||
htmleNBFailureMsg += statMsg
|
htmleNBFailureMsg += statMsg
|
||||||
|
|
||||||
#real time statistics statistics
|
#real time statistics
|
||||||
|
datalog_rt_stats['Data']={}
|
||||||
if len(real_time_stats)!=0: #check if dictionary is not empty
|
if len(real_time_stats)!=0: #check if dictionary is not empty
|
||||||
statMsg=''
|
for k in real_time_stats:
|
||||||
for key in real_time_stats: #for each dictionary key
|
tmp=re.match(r'^(?P<metric>.*):\s+(?P<avg>\d+\.\d+) us;\s+\d+;\s+(?P<max>\d+\.\d+) us;',real_time_stats[k])
|
||||||
statMsg += real_time_stats[key] + '\n'
|
if tmp is not None:
|
||||||
logging.debug(real_time_stats[key])
|
metric=tmp.group('metric')
|
||||||
htmleNBFailureMsg += statMsg
|
avg=float(tmp.group('avg'))
|
||||||
|
max=float(tmp.group('max'))
|
||||||
|
datalog_rt_stats['Data'][metric]=["{:.0f}".format(avg),"{:.0f}".format(max),"{:.2f}".format(avg/datalog_rt_stats['Ref'][metric])]
|
||||||
|
#once all metrics are collected, store the data as a class attribute to build a dedicated HTML table afterward
|
||||||
|
self.datalog_rt_stats=datalog_rt_stats
|
||||||
|
#check if there is a fail => will render the test as failed
|
||||||
|
for k in datalog_rt_stats['Data']:
|
||||||
|
if float(datalog_rt_stats['Data'][k][2])> datalog_rt_stats['Threshold'][k]: #condition for fail : avg/ref is greater than the fixed threshold
|
||||||
|
#setting prematureExit is ok although not the best option
|
||||||
|
self.prematureExit=True
|
||||||
else:
|
else:
|
||||||
statMsg = 'No real time stats found in the log file\n'
|
statMsg = 'No real time stats found in the log file\n'
|
||||||
logging.debug('No real time stats found in the log file')
|
logging.debug('No real time stats found in the log file')
|
||||||
|
|||||||
@@ -40,6 +40,8 @@ import shlex #lexical analysis
|
|||||||
import json #json structures
|
import json #json structures
|
||||||
import datetime #now() and date formating
|
import datetime #now() and date formating
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
|
import re
|
||||||
|
import gitlab
|
||||||
|
|
||||||
#-----------------------------------------------------------
|
#-----------------------------------------------------------
|
||||||
# Class Declaration
|
# Class Declaration
|
||||||
@@ -79,7 +81,7 @@ class gDashboard:
|
|||||||
#line 2 empty
|
#line 2 empty
|
||||||
#line 3 is for the column names
|
#line 3 is for the column names
|
||||||
i=3
|
i=3
|
||||||
row =["MR","Created_at","Author","Title","Assignee", "Reviewer", "CAN START","IN PROGRESS","COMPLETED","OK MERGE","Merge conflicts"]
|
row =["MR","Created_at","Author","Title","Assignee", "Reviewer", "CAN START","IN PROGRESS","COMPLETED","Review Form","OK MERGE","Merge conflicts"]
|
||||||
self.sheet.insert_row(row, index=i, value_input_option='RAW')
|
self.sheet.insert_row(row, index=i, value_input_option='RAW')
|
||||||
|
|
||||||
#line 4 onward, MR data lines
|
#line 4 onward, MR data lines
|
||||||
@@ -120,10 +122,32 @@ class gDashboard:
|
|||||||
else:
|
else:
|
||||||
conflicts = ""
|
conflicts = ""
|
||||||
|
|
||||||
|
|
||||||
|
#add a column flagging that the review form is present
|
||||||
|
#we use gitlab API to parse the MR notes
|
||||||
|
gl = gitlab.Gitlab.from_config('OAI')
|
||||||
|
project_id = 223
|
||||||
|
project = gl.projects.get(project_id)
|
||||||
|
#get the opened MR in the project
|
||||||
|
mrs = project.mergerequests.list(state='opened')
|
||||||
|
for m in range (0,len(mrs)):
|
||||||
|
if mrs[m].iid==self.d[x]['iid']:#check the iid is the one we are on
|
||||||
|
mr_notes = mrs[m].notes.list(all=True)
|
||||||
|
n=0
|
||||||
|
found=False
|
||||||
|
review_form=""
|
||||||
|
while found==False and n<len(mr_notes):
|
||||||
|
res=re.search('Code Review by',mr_notes[n].body)#this is the marker we are looking for in all notes
|
||||||
|
if res!=None:
|
||||||
|
review_form = "X"
|
||||||
|
found=True
|
||||||
|
n+=1
|
||||||
|
|
||||||
|
|
||||||
#build final row to be inserted, the first column is left empty for now, will be filled afterward with hyperlinks to gitlab MR
|
#build final row to be inserted, the first column is left empty for now, will be filled afterward with hyperlinks to gitlab MR
|
||||||
row =["", str(date_time_obj.date()),str(self.d[x]['author']['name']),str(self.d[x]['title']),\
|
row =["", str(date_time_obj.date()),str(self.d[x]['author']['name']),str(self.d[x]['title']),\
|
||||||
assignee, reviewer,\
|
assignee, reviewer,\
|
||||||
milestone1,milestone2,milestone3,milestone4,conflicts]
|
milestone1,milestone2,milestone3,review_form,milestone4,conflicts]
|
||||||
|
|
||||||
#insert the row to worksheet
|
#insert the row to worksheet
|
||||||
self.sheet.insert_row(row, index=i, value_input_option='RAW')
|
self.sheet.insert_row(row, index=i, value_input_option='RAW')
|
||||||
@@ -246,10 +270,10 @@ class gDashboard:
|
|||||||
"sheetId": sheetId,
|
"sheetId": sheetId,
|
||||||
"dimension": "COLUMNS",
|
"dimension": "COLUMNS",
|
||||||
"startIndex": 6,
|
"startIndex": 6,
|
||||||
"endIndex": 10
|
"endIndex": 11
|
||||||
},
|
},
|
||||||
"properties": {
|
"properties": {
|
||||||
"pixelSize": 135
|
"pixelSize": 120
|
||||||
},
|
},
|
||||||
"fields": "pixelSize"
|
"fields": "pixelSize"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -568,33 +568,6 @@ function report_build {
|
|||||||
|
|
||||||
echo " <h2>Ubuntu 16.04 LTS -- Summary</h2>" >> ./build_results.html
|
echo " <h2>Ubuntu 16.04 LTS -- Summary</h2>" >> ./build_results.html
|
||||||
|
|
||||||
if [ -f ./archives/cppcheck/cppcheck.xml ]
|
|
||||||
then
|
|
||||||
sca_summary_table_header ./archives/cppcheck/cppcheck.xml "OAI Static Code Analysis with CPPCHECK"
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Uninitialized variable" uninitvar
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Uninitialized struct member" uninitStructMember
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Memory leak" memleak
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Memory is freed twice" doubleFree
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Resource leak" resourceLeak
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Possible null pointer dereference" nullPointer
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Array access out of bounds" arrayIndexOutOfBounds
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Buffer is accessed out of bounds" bufferAccessOutOfBounds
|
|
||||||
sca_summary_table_row ./archives/cppcheck/cppcheck.xml "Expression depends on order of evaluation of side effects" unknownEvaluationOrder
|
|
||||||
sca_summary_table_footer ./archives/cppcheck/cppcheck.xml
|
|
||||||
fi
|
|
||||||
|
|
||||||
# summary_table_header "OAI Build: 4G LTE eNB -- USRP option" ./archives/enb_usrp
|
|
||||||
# summary_table_row "LTE SoftModem - Release 15" ./archives/enb_usrp/lte-softmodem.Rel15.txt "Built target lte-softmodem" ./enb_usrp_row1.html
|
|
||||||
# summary_table_row "Coding - Release 15" ./archives/enb_usrp/coding.Rel15.txt "Built target coding" ./enb_usrp_row2.html
|
|
||||||
# summary_table_row "OAI USRP device if - Release 15" ./archives/enb_usrp/oai_usrpdevif.Rel15.txt "Built target oai_usrpdevif" ./enb_usrp_row3.html
|
|
||||||
# summary_table_row "OAI ETHERNET transport - Release 15" ./archives/enb_usrp/oai_eth_transpro.Rel15.txt "Built target oai_eth_transpro" ./enb_usrp_row4.html
|
|
||||||
# summary_table_row "Parameters Lib Config - Release 15" ./archives/enb_usrp/params_libconfig.Rel15.txt "Built target params_libconfig" ./enb_usrp_row5.html
|
|
||||||
# summary_table_row "NASMESH - Release 15" ./archives/enb_usrp/nasmesh.Rel15.txt "Built target nasmesh" ./enb_usrp_row6.html
|
|
||||||
# summary_table_row "RB Tool - Release 15" ./archives/enb_usrp/rb_tool.Rel15.txt "Built target rb_tool" ./enb_usrp_row7.html
|
|
||||||
# summary_table_row "RF Simulator - Release 15" ./archives/enb_usrp/rfsimulator.Rel15.txt "Built target rfsimulator" ./enb_usrp_row8.html
|
|
||||||
# summary_table_row "TCP Bridge - Release 15" ./archives/enb_usrp/tcp_bridge_oai.Rel15.txt "Built target tcp_bridge_oai" ./enb_usrp_row9.html
|
|
||||||
# summary_table_footer
|
|
||||||
#
|
|
||||||
summary_table_header "OAI Build: 4G LTE eNB -- USRP option" ./archives/enb_eth
|
summary_table_header "OAI Build: 4G LTE eNB -- USRP option" ./archives/enb_eth
|
||||||
summary_table_row "LTE SoftModem - Release 15" ./archives/enb_eth/lte-softmodem.Rel15.txt "Built target lte-softmodem" ./enb_eth_row1.html
|
summary_table_row "LTE SoftModem - Release 15" ./archives/enb_eth/lte-softmodem.Rel15.txt "Built target lte-softmodem" ./enb_eth_row1.html
|
||||||
summary_table_row "Coding - Release 15" ./archives/enb_eth/coding.Rel15.txt "Built target coding" ./enb_eth_row2.html
|
summary_table_row "Coding - Release 15" ./archives/enb_eth/coding.Rel15.txt "Built target coding" ./enb_eth_row2.html
|
||||||
@@ -637,48 +610,6 @@ function report_build {
|
|||||||
summary_table_row "NVRAM - Release 15" ./archives/basic_sim/nvram.Rel15.txt "Built target nvram" ./basic_sim_row13.html
|
summary_table_row "NVRAM - Release 15" ./archives/basic_sim/nvram.Rel15.txt "Built target nvram" ./basic_sim_row13.html
|
||||||
summary_table_footer
|
summary_table_footer
|
||||||
|
|
||||||
summary_table_header "OAI Build: 4G LTE / 5G NR Physical simulators option" ./archives/phy_sim
|
|
||||||
summary_table_row "LTE DL Simulator - Release 15" ./archives/phy_sim/dlsim.Rel15.txt "Built target dlsim" ./phy_sim_row1.html
|
|
||||||
summary_table_row "LTE UL Simulator - Release 15" ./archives/phy_sim/ulsim.Rel15.txt "Built target ulsim" ./phy_sim_row2.html
|
|
||||||
summary_table_row "Coding - Release 15" ./archives/phy_sim/coding.Rel15.txt "Built target coding" ./phy_sim_row3.html
|
|
||||||
if [ -f ./archives/phy_sim/ldpctest.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR LDPC Test - Release 15" ./archives/phy_sim/ldpctest.Rel15.txt "Built target ldpctest" ./phy_sim_row4.html
|
|
||||||
fi
|
|
||||||
if [ -f ./archives/phy_sim/polartest.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR Polar Test - Release 15" ./archives/phy_sim/polartest.Rel15.txt "Built target polartest" ./phy_sim_row5.html
|
|
||||||
fi
|
|
||||||
if [ -f ./archives/phy_sim/nr_pbchsim.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR PBCH Test - Release 15" ./archives/phy_sim/nr_pbchsim.Rel15.txt "Built target nr_pbchsim" ./phy_sim_row6.html
|
|
||||||
fi
|
|
||||||
if [ -f ./archives/phy_sim/nr_dlschsim.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR DLSCH Test - Release 15" ./archives/phy_sim/nr_dlschsim.Rel15.txt "Built target nr_dlschsim" ./phy_sim_row7.html
|
|
||||||
fi
|
|
||||||
if [ -f ./archives/phy_sim/nr_pucchsim.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR PUCCH Test - Release 15" ./archives/phy_sim/nr_pucchsim.Rel15.txt "Built target nr_pucchsim" ./phy_sim_row8.html
|
|
||||||
fi
|
|
||||||
if [ -f ./archives/phy_sim/smallblocktest.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR Small Block Test - Release 15" ./archives/phy_sim/smallblocktest.Rel15.txt "Built target smallblocktest" ./phy_sim_row9.html
|
|
||||||
fi
|
|
||||||
if [ -f ./archives/phy_sim/nr_dlsim.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR DL Sim Test - Release 15" ./archives/phy_sim/nr_dlsim.Rel15.txt "Built target nr_dlsim" ./phy_sim_row10.html
|
|
||||||
fi
|
|
||||||
if [ -f ./archives/phy_sim/nr_ulschsim.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR ULSCH Test - Release 15" ./archives/phy_sim/nr_ulschsim.Rel15.txt "Built target nr_ulschsim" ./phy_sim_row11.html
|
|
||||||
fi
|
|
||||||
if [ -f ./archives/phy_sim/nr_ulsim.Rel15.txt ]
|
|
||||||
then
|
|
||||||
summary_table_row "NR UL Sim Test - Release 15" ./archives/phy_sim/nr_ulsim.Rel15.txt "Built target nr_ulsim" ./phy_sim_row12.html
|
|
||||||
fi
|
|
||||||
summary_table_footer
|
|
||||||
|
|
||||||
if [ -f archives/gnb_usrp/nr-softmodem.Rel15.txt ]
|
if [ -f archives/gnb_usrp/nr-softmodem.Rel15.txt ]
|
||||||
then
|
then
|
||||||
summary_table_header "OAI Build: 5G NR gNB -- USRP option" ./archives/gnb_usrp
|
summary_table_header "OAI Build: 5G NR gNB -- USRP option" ./archives/gnb_usrp
|
||||||
@@ -721,13 +652,6 @@ function report_build {
|
|||||||
echo " <button data-toggle=\"collapse\" data-target=\"#oai-compilation-details\">Details for Compilation Errors and Warnings </button>" >> ./build_results.html
|
echo " <button data-toggle=\"collapse\" data-target=\"#oai-compilation-details\">Details for Compilation Errors and Warnings </button>" >> ./build_results.html
|
||||||
echo " <div id=\"oai-compilation-details\" class=\"collapse\">" >> ./build_results.html
|
echo " <div id=\"oai-compilation-details\" class=\"collapse\">" >> ./build_results.html
|
||||||
|
|
||||||
# if [ -f ./enb_usrp_row1.html ] || [ -f ./enb_usrp_row2.html ] || [ -f ./enb_usrp_row3.html ] || [ -f ./enb_usrp_row4.html ]
|
|
||||||
# then
|
|
||||||
# for DETAILS_TABLE in `ls ./enb_usrp_row*.html`
|
|
||||||
# do
|
|
||||||
# cat $DETAILS_TABLE >> ./build_results.html
|
|
||||||
# done
|
|
||||||
# fi
|
|
||||||
if [ -f ./enb_eth_row1.html ] || [ -f ./enb_eth_row2.html ] || [ -f ./enb_eth_row3.html ] || [ -f ./enb_eth_row4.html ] || [ -f ./enb_eth_row5.html ] || [ -f ./enb_eth_row6.html ] || [ -f ./enb_eth_row7.html ] || [ -f ./enb_eth_row8.html ] || [ -f ./enb_eth_row9.html ]
|
if [ -f ./enb_eth_row1.html ] || [ -f ./enb_eth_row2.html ] || [ -f ./enb_eth_row3.html ] || [ -f ./enb_eth_row4.html ] || [ -f ./enb_eth_row5.html ] || [ -f ./enb_eth_row6.html ] || [ -f ./enb_eth_row7.html ] || [ -f ./enb_eth_row8.html ] || [ -f ./enb_eth_row9.html ]
|
||||||
then
|
then
|
||||||
for DETAILS_TABLE in `ls ./enb_eth_row*.html`
|
for DETAILS_TABLE in `ls ./enb_eth_row*.html`
|
||||||
@@ -749,13 +673,6 @@ function report_build {
|
|||||||
cat $DETAILS_TABLE >> ./build_results.html
|
cat $DETAILS_TABLE >> ./build_results.html
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
if [ -f ./phy_sim_row1.html ] || [ -f ./phy_sim_row2.html ] || [ -f ./phy_sim_row3.html ] || [ -f ./phy_sim_row4.html ] || [ -f ./phy_sim_row5.html ] || [ -f ./phy_sim_row6.html ] || [ -f ./phy_sim_row7.html ] || [ -f ./phy_sim_row8.html ]
|
|
||||||
then
|
|
||||||
for DETAILS_TABLE in `ls ./phy_sim_row*.html`
|
|
||||||
do
|
|
||||||
cat $DETAILS_TABLE >> ./build_results.html
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
if [ -f ./gnb_usrp_row1.html ] || [ -f ./gnb_usrp_row2.html ] || [ -f ./gnb_usrp_row3.html ] || [ -f ./gnb_usrp_row4.html ]
|
if [ -f ./gnb_usrp_row1.html ] || [ -f ./gnb_usrp_row2.html ] || [ -f ./gnb_usrp_row3.html ] || [ -f ./gnb_usrp_row4.html ]
|
||||||
then
|
then
|
||||||
for DETAILS_TABLE in `ls ./gnb_usrp_row*.html`
|
for DETAILS_TABLE in `ls ./gnb_usrp_row*.html`
|
||||||
@@ -770,13 +687,6 @@ function report_build {
|
|||||||
cat $DETAILS_TABLE >> ./build_results.html
|
cat $DETAILS_TABLE >> ./build_results.html
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
if [ -f ./enb_usrp_rh_row1.html ] || [ -f ./enb_usrp_rh_row2.html ] || [ -f ./enb_usrp_rh_row3.html ] || [ -f ./enb_usrp_rh_row4.html ]
|
|
||||||
then
|
|
||||||
for DETAILS_TABLE in `ls ./enb_usrp_rh_row*.html`
|
|
||||||
do
|
|
||||||
cat $DETAILS_TABLE >> ./build_results.html
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
rm -f ./*_row*.html
|
rm -f ./*_row*.html
|
||||||
|
|
||||||
echo " </div>" >> ./build_results.html
|
echo " </div>" >> ./build_results.html
|
||||||
|
|||||||
@@ -1478,13 +1478,13 @@ function run_test_on_vm {
|
|||||||
echo "$VM_NAME has for IP addr = $VM_IP_ADDR"
|
echo "$VM_NAME has for IP addr = $VM_IP_ADDR"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$RUN_OPTIONS" == "none" ]
|
if [ "$RUN_OPTIONS" == "none" ] || [[ $RUN_OPTIONS =~ .*run_exec_autotests.* ]]
|
||||||
then
|
then
|
||||||
echo "No run on VM testing for this variant currently"
|
echo "No run on VM testing for this variant currently"
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ $RUN_OPTIONS =~ .*run_exec_autotests.* ]]
|
if [[ $RUN_OPTIONS =~ .*run_XXXX_autotests.* ]]
|
||||||
then
|
then
|
||||||
echo "############################################################"
|
echo "############################################################"
|
||||||
echo "Running test script on VM ($VM_NAME)"
|
echo "Running test script on VM ($VM_NAME)"
|
||||||
|
|||||||
@@ -111,11 +111,20 @@ class SSHConnection():
|
|||||||
self.sshresponse = self.ssh.expect(expected)
|
self.sshresponse = self.ssh.expect(expected)
|
||||||
return self.sshresponse
|
return self.sshresponse
|
||||||
|
|
||||||
def command(self, commandline, expectedline, timeout):
|
def command(self, commandline, expectedline, timeout, silent=False, resync=False):
|
||||||
logging.debug(commandline)
|
if not silent:
|
||||||
|
logging.debug(commandline)
|
||||||
self.ssh.timeout = timeout
|
self.ssh.timeout = timeout
|
||||||
self.ssh.sendline(commandline)
|
# Nasty patch when pexpect output is out of sync.
|
||||||
self.sshresponse = self.ssh.expect([expectedline, pexpect.EOF, pexpect.TIMEOUT])
|
# Much pronounced when running back-to-back-back oc commands
|
||||||
|
if resync:
|
||||||
|
self.ssh.send(commandline)
|
||||||
|
self.ssh.expect([commandline, pexpect.TIMEOUT])
|
||||||
|
self.ssh.send('\r\n')
|
||||||
|
self.sshresponse = self.ssh.expect([expectedline, pexpect.EOF, pexpect.TIMEOUT])
|
||||||
|
else:
|
||||||
|
self.ssh.sendline(commandline)
|
||||||
|
self.sshresponse = self.ssh.expect([expectedline, pexpect.EOF, pexpect.TIMEOUT])
|
||||||
if self.sshresponse == 0:
|
if self.sshresponse == 0:
|
||||||
return 0
|
return 0
|
||||||
elif self.sshresponse == 1:
|
elif self.sshresponse == 1:
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ function wait_on_vm_build {
|
|||||||
echo "ARCHIVES_LOC = $ARCHIVES_LOC"
|
echo "ARCHIVES_LOC = $ARCHIVES_LOC"
|
||||||
echo "BUILD_OPTIONS = $BUILD_OPTIONS"
|
echo "BUILD_OPTIONS = $BUILD_OPTIONS"
|
||||||
|
|
||||||
if [[ "$VM_NAME" == *"-enb-usrp"* ]] || [[ "$VM_NAME" == *"-cppcheck"* ]]
|
if [[ "$VM_NAME" == *"-enb-usrp"* ]] || [[ "$VM_NAME" == *"-cppcheck"* ]] || [[ "$VM_NAME" == *"-phy-sim"* ]]
|
||||||
then
|
then
|
||||||
echo "This VM type is no longer supported in the pipeline framework"
|
echo "This VM type is no longer supported in the pipeline framework"
|
||||||
return
|
return
|
||||||
@@ -93,7 +93,7 @@ function wait_on_vm_build {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function check_on_vm_build {
|
function check_on_vm_build {
|
||||||
if [[ "$VM_NAME" == *"-enb-usrp"* ]] || [[ "$VM_NAME" == *"-cppcheck"* ]]
|
if [[ "$VM_NAME" == *"-enb-usrp"* ]] || [[ "$VM_NAME" == *"-cppcheck"* ]] || [[ "$VM_NAME" == *"-phy-sim"* ]]
|
||||||
then
|
then
|
||||||
echo "This VM type is no longer supported in the pipeline framework"
|
echo "This VM type is no longer supported in the pipeline framework"
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -38,3 +38,4 @@
|
|||||||
- Deploy_Object
|
- Deploy_Object
|
||||||
- Undeploy_Object
|
- Undeploy_Object
|
||||||
- Cppcheck_Analysis
|
- Cppcheck_Analysis
|
||||||
|
- Deploy_Run_PhySim
|
||||||
@@ -24,7 +24,7 @@
|
|||||||
<htmlTabRef>gNB-PHY-Test</htmlTabRef>
|
<htmlTabRef>gNB-PHY-Test</htmlTabRef>
|
||||||
<htmlTabName>Run-gNB-PHY-Test</htmlTabName>
|
<htmlTabName>Run-gNB-PHY-Test</htmlTabName>
|
||||||
<htmlTabIcon>tasks</htmlTabIcon>
|
<htmlTabIcon>tasks</htmlTabIcon>
|
||||||
<repeatCount>2</repeatCount>
|
<repeatCount>3</repeatCount>
|
||||||
<TestCaseRequestedList>
|
<TestCaseRequestedList>
|
||||||
090101 000001 090109
|
090101 000001 090109
|
||||||
</TestCaseRequestedList>
|
</TestCaseRequestedList>
|
||||||
@@ -40,7 +40,7 @@
|
|||||||
<testCase id="000001">
|
<testCase id="000001">
|
||||||
<class>IdleSleep</class>
|
<class>IdleSleep</class>
|
||||||
<desc>Sleep</desc>
|
<desc>Sleep</desc>
|
||||||
<idle_sleep_time_in_sec>180</idle_sleep_time_in_sec>
|
<idle_sleep_time_in_sec>300</idle_sleep_time_in_sec>
|
||||||
</testCase>
|
</testCase>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,37 @@
|
|||||||
|
<!--
|
||||||
|
|
||||||
|
Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
|
||||||
|
contributor license agreements. See the NOTICE file distributed with
|
||||||
|
this work for additional information regarding copyright ownership.
|
||||||
|
The OpenAirInterface Software Alliance licenses this file to You under
|
||||||
|
the OAI Public License, Version 1.1 (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.openairinterface.org/?page_id=698
|
||||||
|
|
||||||
|
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.
|
||||||
|
|
||||||
|
For more information about the OpenAirInterface (OAI) Software Alliance:
|
||||||
|
contact@openairinterface.org
|
||||||
|
|
||||||
|
-->
|
||||||
|
<testCaseList>
|
||||||
|
<htmlTabRef>build-tab</htmlTabRef>
|
||||||
|
<htmlTabName>Physical Simulators Check</htmlTabName>
|
||||||
|
<htmlTabIcon>wrench</htmlTabIcon>
|
||||||
|
<TestCaseRequestedList>
|
||||||
|
010201
|
||||||
|
</TestCaseRequestedList>
|
||||||
|
<TestCaseExclusionList></TestCaseExclusionList>
|
||||||
|
|
||||||
|
<testCase id="010201">
|
||||||
|
<class>Deploy_Run_PhySim</class>
|
||||||
|
<desc>Deploy and run physical simulator on openshift</desc>
|
||||||
|
</testCase>
|
||||||
|
|
||||||
|
</testCaseList>
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user