blob: 5546e1cf547c2fa9960f46d296182f438eec3362 [file] [log] [blame]
badhri854c028b32021-11-03 18:24:05 -05001#!/bin/sh
2
3# Copyright 2020-present Open Networking Foundation
4#
Ajay Lotan Thakur03189d22022-02-10 14:06:03 -06005# SPDX-License-Identifier: Apache-2.0
badhri854c028b32021-11-03 18:24:05 -05006
7set -xe
8
9{{- if .Values.config.coreDump.enabled }}
Ajay Lotan Thakur4ebd7e82022-01-14 09:11:42 -070010cp /gnbsim/bin/gnbsim /tmp/coredump/
badhri854c028b32021-11-03 18:24:05 -050011{{- end }}
12
Ajay Lotan Thakur4ebd7e82022-01-14 09:11:42 -070013cd /gnbsim
badhri854c028b32021-11-03 18:24:05 -050014cat ./config/gnb.conf
15cat /etc/hosts
Ajay Lotan Thakur0203c3b2022-03-21 13:40:11 -060016
Vijaya Tiruveedula56f595f2022-10-27 05:28:50 -060017{{- define "gnbiplist" -}}
18{{- join "," .Values.config.gnbsim.gnb.ips }}
19{{- end -}}
20
Ajay Lotan Thakur0203c3b2022-03-21 13:40:11 -060021{{- if not .Values.config.gnbsim.singleInterface }}
22{{- range .Values.config.gnbsim.networkTopo }}
Hyunsun Moon2b21eb42022-03-24 01:52:22 -060023ip route replace {{ .upfAddr }} via {{ .upfGw }}
24{{- end }}
Ajay Lotan Thakur0203c3b2022-03-21 13:40:11 -060025{{- end }}
26
Badhrinath Padmanabhana0c93b72022-11-21 21:53:00 -060027{{- if .Values.config.gnbsim.httpServer.enable}}
28cd /gnbsim
29./bin/gnbsim --cfg ./config/gnb.conf
30{{- else }}
badhri854c028b32021-11-03 18:24:05 -050031sleep infinity
Badhrinath Padmanabhana0c93b72022-11-21 21:53:00 -060032{{- end }}