Add ttcn3-ns-test container

Change-Id: I45d211f4edd39e5be8f63185f1b7bd100fb2644b
Related: OS#5396
changes/57/23557/2
Harald Welte 2 years ago
parent 3fc5b8af4e
commit 3862858434
  1. 13
      ttcn3-ns-test/Dockerfile
  2. 1
      ttcn3-ns-test/Makefile
  3. 33
      ttcn3-ns-test/NS_Tests.cfg
  4. 39
      ttcn3-ns-test/jenkins.sh
  5. 94
      ttcn3-ns-test/osmo-ns-dummy.cfg

@ -0,0 +1,13 @@
ARG REGISTRY
ARG USER
FROM $REGISTRY/$USER/debian-stretch-titan
ARG OSMO_TTCN3_BRANCH="master"
ADD http://git.osmocom.org/osmo-ttcn3-hacks/patch?h=$OSMO_TTCN3_BRANCH /tmp/commit
RUN ttcn3-docker-prepare "$OSMO_TTCN3_BRANCH" ns
VOLUME /data
COPY NS_Tests.cfg /data/NS_Tests.cfg
CMD ttcn3-docker-run ns NS_Tests

@ -0,0 +1 @@
include ../make/Makefile

@ -0,0 +1,33 @@
[ORDERED_INCLUDE]
"/osmo-ttcn3-hacks/Common.cfg"
"/osmo-ttcn3-hacks/ns/NS_Tests.default"
[LOGGING]
[TESTPORT_PARAMETERS]
*.NSVTY.CTRL_HOSTNAME := "172.18.28.101"
[MODULE_PARAMETERS]
NS_Tests.mp_nsconfig := {
nsei := 1234,
nsvc := {
{
provider := {
ip := {
address_family := AF_INET,
local_ip := "172.18.28.10",
local_udp_port := 22000,
remote_ip := "172.18.28.101",
remote_udp_port := 23000
}
},
nsvci := 1234
}
}
}
NS_Tests.mp_dialect := NS2_DIALECT_STATIC_RESETBLOCK
[MAIN_CONTROLLER]
[EXECUTE]
NS_Tests.control

@ -0,0 +1,39 @@
#!/bin/sh
. ../jenkins-common.sh
IMAGE_SUFFIX="${IMAGE_SUFFIX:-master}"
docker_images_require \
"osmo-ns-$IMAGE_SUFFIX" \
"ttcn3-ns-test"
set_clean_up_trap
set -e
SUBNET=28
network_create $SUBNET
mkdir $VOL_BASE_DIR/ns-tester
cp NS_Tests.cfg $VOL_BASE_DIR/ns-tester/
mkdir $VOL_BASE_DIR/ns
cp osmo-ns-dummy.cfg $VOL_BASE_DIR/ns/
echo Starting container with osmo-ns-dummy
docker run --rm \
$(docker_network_params $SUBNET 101) \
--ulimit core=-1 \
-v $VOL_BASE_DIR/ns:/data \
--name ${BUILD_TAG}-ns -d \
$DOCKER_ARGS \
$REPO_USER/osmo-ns-$IMAGE_SUFFIX \
/bin/sh -c "/usr/local/bin/osmo-ns-dummy -c /data/osmo-ns-dummy.cfg -p 4240 >>/data/osmo-ns-dummy.log 2>&1"
echo Starting container with NS testsuite
docker run --rm \
$(docker_network_params $SUBNET 10) \
--ulimit core=-1 \
-e "TTCN3_PCAP_PATH=/data" \
-v $VOL_BASE_DIR/ns-tester:/data \
--name ${BUILD_TAG}-ttcn3-ns-test \
$DOCKER_ARGS \
$REPO_USER/ttcn3-ns-test

@ -0,0 +1,94 @@
!
! OsmoNSdummy (1.4.0.326-f57c-dirty) configuration saved from vty
!!
!
log stderr
logging filter all 1
logging color 0
logging print category-hex 0
logging print category 1
logging print extended-timestamp 1
logging print level 1
logging print file basename
logging level force-all info
logging level lglobal debug
logging level llapd debug
logging level linp debug
logging level lmux debug
logging level lmi debug
logging level lmib debug
logging level lsms debug
logging level lctrl debug
logging level lgtp debug
logging level lstats debug
logging level lgsup debug
logging level loap debug
logging level lss7 debug
logging level lsccp debug
logging level lsua debug
logging level lm3ua debug
logging level lmgcp debug
logging level ljibuf debug
logging level lrspro debug
logging level lns debug
logging level lbssgp debug
log gsmtap 172.18.28.10
logging filter all 0
logging color 1
logging print category-hex 1
logging print category 0
logging timestamp 0
logging print file 1
logging level lglobal debug
logging level llapd debug
logging level linp debug
logging level lmux debug
logging level lmi debug
logging level lmib debug
logging level lsms debug
logging level lctrl debug
logging level lgtp debug
logging level lstats debug
logging level lgsup debug
logging level loap debug
logging level lss7 debug
logging level lsccp debug
logging level lsua debug
logging level lm3ua debug
logging level lmgcp debug
logging level ljibuf debug
logging level lrspro debug
logging level lns debug
logging level lbssgp debug
!
stats reporter statsd
disable
remote-ip 172.18.28.10
remote-port 8125
mtu 1024
level subscriber
prefix TTCN3
flush-period 1
enable
stats interval 0
!
line vty
no login
bind 172.18.28.101
!
ns
timer tns-block 3
timer tns-block-retries 3
timer tns-reset 3
timer tns-reset-retries 3
timer tns-test 12
timer tns-alive 3
timer tns-alive-retries 3
timer tsns-prov 3
timer tsns-size-retries 3
timer tsns-config-retries 3
bind udp local
listen 172.18.28.101 23000
accept-ipaccess
nse 1234
nsvc ipa local 172.18.28.10 22000 nsvci 1234
Loading…
Cancel
Save