Add ttcn3-msc-test container with OsmoMSC test suite

changes/84/7384/1
Harald Welte 5 years ago
parent f83fe4c7cb
commit 8fc4202fae
  1. 2
      ttcn3-msc-test/.release
  2. 26
      ttcn3-msc-test/Dockerfile
  3. 50
      ttcn3-msc-test/MSC_Tests.cfg
  4. 3
      ttcn3-msc-test/Makefile
  5. 58
      ttcn3-msc-test/jenkins.sh
  6. 82
      ttcn3-msc-test/osmo-msc.cfg
  7. 45
      ttcn3-msc-test/osmo-stp.cfg

@ -0,0 +1,2 @@
release=0.0.0
tag=ttcn3-msc-test-0.0.0

@ -0,0 +1,26 @@
FROM laforge/debian-stretch-titan
RUN mkdir /root/projects && (cd /root/projects && ln -sf / git)
RUN git clone git://git.osmocom.org/osmo-ttcn3-hacks.git
RUN cd osmo-ttcn3-hacks && \
git checkout -f -B master origin/master && \
make deps
RUN git config --global user.email docker@dock.er && \
git config --global user.name "Dock Er"
ADD http://git.osmocom.org/osmo-ttcn3-hacks/patch /tmp/commit
RUN cd osmo-ttcn3-hacks && \
git fetch && \
git checkout -f -B master origin/master && \
git cherry-pick 5ce5241d6d460e9b36a908ac7072d8ea68df08db && \
make msc
VOLUME /data
COPY MSC_Tests.cfg /data/MSC_Tests.cfg
CMD cd /data && \
/osmo-ttcn3-hacks/start-testsuite.sh /osmo-ttcn3-hacks/msc/MSC_Tests && \
ttcn3_logmerge MSC*.log

@ -0,0 +1,50 @@
[LOGGING]
SourceInfoFormat := Single;
#FileMask := LOG_ALL | TTCN_DEBUG | TTCN_MATCHING | DEBUG_ENCDEC;
#ConsoleMask := ERROR | WARNING | TESTCASE | TTCN_MATCHING | DEBUG_ENCDEC
FileMask := LOG_ALL | TTCN_MATCHING;
BSSAP.FileMask := LOG_NOTHING;
"MSC_Test-M3UA".FileMask := ERROR | WARNING;
"MSC_Test-SCCP".FileMask := ERROR | WARNING;
"MSC_Test-GSUP-IPA".FileMask := ERROR | WARNING;
"MSC_Test-GSUP".FileMask := ERROR | WARNING;
"IPA-CTRL-IPA".FileMask := ERROR | WARNING;
mtc.FileMask := LOG_ALL | TTCN_DEBUG | TTCN_MATCHING | DEBUG_ENCDEC;
LogSourceInfo := Yes
LoggerPlugins := { JUnitLogger := "libjunitlogger2" }
*.JUnitLogger.testsuite_name := "MSC_Tests"
[TESTPORT_PARAMETERS]
#*.*.udpReuseAddress := "yes";
"MSC_Test-MNCC".MNCC.socket_type := "SEQPACKET";
*.MSCVTY.CTRL_MODE := "client"
*.MSCVTY.CTRL_HOSTNAME := "172.18.0.10"
*.MSCVTY.CTRL_PORTNUM := "4254"
*.MSCVTY.CTRL_LOGIN_SKIPPED := "yes"
*.MSCVTY.CTRL_DETECT_SERVER_DISCONNECTED := "yes"
*.MSCVTY.CTRL_READMODE := "buffered"
*.MSCVTY.CTRL_CLIENT_CLEANUP_LINEFEED := "yes"
*.MSCVTY.PROMPT1 := "OsmoMSC> "
[MODULE_PARAMETERS]
M3UA_Emulation.tsp_logVerbose := true;
# connection to STP
BSSAP_Adapter.mp_own_pc := 193; /* 0.23.3 */
BSSAP_Adapter.mp_peer_pc := 185; /* 0.23.1 */
BSSAP_Adapter.mp_sctp_addr := { 23906, "172.18.0.103", 2905, "172.18.0.200" };
# VTY prompt prefix
Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoMSC";
# remote (IUT) side
MSC_Tests.mp_msc_mncc := "/data/unix/mncc";
MSC_Tests.mp_msc_ip := "172.18.0.10";
# local (emulation) side)
MSC_Tests.mp_hlr_ip := "172.18.0.103";
MSC_Tests.mp_mgw_ip := "172.18.0.103";
[MAIN_CONTROLLER]
[EXECUTE]
MSC_Tests.control

@ -0,0 +1,3 @@
RUN_ARGS?=--sysctl net.ipv6.conf.all.disable_ipv6=0 --rm --network sigtran --ip 172.18.0.202 -v ggsn-test-vol:/data
include ../make/Makefile

@ -0,0 +1,58 @@
#!/bin/sh
# non-jenkins execution: assume local user name
if [ "x$REPO_USER" = "x" ]; then
REPO_USER=$USER
fi
# non-jenkins execution: put logs in /tmp
if [ "x$WORKSPACE" = "x" ]; then
WORKSPACE=/tmp
fi
VOL_BASE_DIR=`mktemp -d`
mkdir $VOL_BASE_DIR/msc-tester
mkdir $VOL_BASE_DIR/msc-tester/unix
cp MSC_Tests.cfg $VOL_BASE_DIR/msc-tester/
mkdir $VOL_BASE_DIR/stp
cp osmo-stp.cfg $VOL_BASE_DIR/stp/
mkdir $VOL_BASE_DIR/msc
mkdir $VOL_BASE_DIR/msc/unix
cp osmo-msc.cfg $VOL_BASE_DIR/msc/
mkdir $VOL_BASE_DIR/unix
echo Starting container with STP
docker run --rm \
--network sigtran --ip 172.18.0.200 \
-v $VOL_BASE_DIR/stp:/data \
--name stp -d \
$REPO_USER/osmo-stp-master
echo Starting container with MSC
docker run --rm \
--network sigtran --ip 172.18.0.10 \
-v $VOL_BASE_DIR/msc:/data \
-v $VOL_BASE_DIR/unix:/data/unix \
--name msc -d \
$REPO_USER/osmo-msc-master \
/usr/local/bin/osmo-msc -M /data/unix/mncc
echo Starting container with MSC testsuite
docker run --rm \
--network sigtran --ip 172.18.0.103 \
-v $VOL_BASE_DIR/msc-tester:/data \
-v $VOL_BASE_DIR/unix:/data/unix \
--name ttcn3-msc-test \
$REPO_USER/ttcn3-msc-test
echo Stopping containers
docker container kill msc
docker container kill stp
rm -rf $WORKSPACE/logs
mkdir -p $WORKSPACE/logs
cp -a $VOL_BASE_DIR/* $WORKSPACE/logs/
#rm -rf $VOL_BASE_DIR

@ -0,0 +1,82 @@
!
! OsmoMSC (1.1.2.66-629c4-dirty) configuration saved from vty
!!
!
log file /data/osmo-msc.log
logging filter all 1
logging color 0
logging print category 1
logging timestamp 1
logging level all everything
logging level rll notice
logging level cc debug
logging level mm debug
logging level rr notice
logging level mncc debug
logging level pag notice
logging level msc notice
logging level mgcp debug
logging level ho notice
logging level db notice
logging level ref notice
logging level ctrl notice
logging level smpp debug
logging level ranap debug
logging level vlr debug
logging level iucs debug
logging level lglobal notice
logging level llapd notice
logging level linp notice
logging level lmux notice
logging level lmi notice
logging level lmib notice
logging level lsms notice
logging level lctrl info
logging level lgtp notice
logging level lstats notice
logging level lgsup notice
logging level loap notice
logging level lss7 notice
logging level lsccp notice
logging level lsua notice
logging level lm3ua notice
logging level lmgcp debug
!
stats interval 5
!
line vty
no login
bind 0.0.0.0
ctrl
bind 0.0.0.0
!
cs7 instance 0
point-code 0.23.1
asp asp-clnt-OsmoMSC-A 2905 0 m3ua
remote-ip 172.18.0.200
as as-clnt-OsmoMSC-A m3ua
asp asp-clnt-OsmoMSC-A
routing-key 2 0.23.1
network
network country code 1
mobile network code 1
short name OsmoMSC
long name OsmoMSC
auth policy closed
location updating reject cause 13
encryption a5 0
authentication optional
rrlp mode none
mm info 1
periodic location update 30
msc
assign-tmsi
cs7-instance-a 0
cs7-instance-iu 0
mgw remote-ip 172.18.0.103
mncc-int
default-codec tch-f fr
default-codec tch-h hr
hlr
remote-ip 172.18.0.103
remote-port 4222

@ -0,0 +1,45 @@
!
! OsmoSTP (0.8.1) configuration saved from vty
!!
!
log stderr
logging filter all 1
logging color 1
logging print category 1
logging timestamp 0
logging level all everything
logging level lglobal notice
logging level llapd notice
logging level linp notice
logging level lmux notice
logging level lmi notice
logging level lmib notice
logging level lsms notice
logging level lctrl notice
logging level lgtp notice
logging level lstats notice
logging level lgsup notice
logging level loap notice
logging level lss7 debug
logging level lsccp debug
logging level lsua debug
logging level lm3ua debug
logging level lmgcp notice
!
line vty
no login
!
cs7 instance 0
xua rkm routing-key-allocation dynamic-permitted
asp virt-bsc0-0 23906 2905 m3ua
local-ip 172.18.0.200
remote-ip 172.18.0.103
as virt-bsc0 m3ua
asp virt-bsc0-0
routing-key 0 0.24.1
route-table system
update route 0.24.1 7.255.7 linkset virt-bsc0
listen m3ua 2905
accept-asp-connections dynamic-permitted
listen ipa 5000
accept-asp-connections dynamic-permitted
Loading…
Cancel
Save