Change in docker-playground[master]: Introduce ttcn3-stp-test

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

pespin gerrit-no-reply at lists.osmocom.org
Tue Oct 29 09:10:22 UTC 2019


pespin has submitted this change. ( https://gerrit.osmocom.org/c/docker-playground/+/15872 )

Change subject: Introduce ttcn3-stp-test
......................................................................

Introduce ttcn3-stp-test

Currently builds from osmo-ttcn3-hacks.git branch laforge/stp instead of
master, since it's only available in the former branch. Once it gets
merged, we can modify Dockerfile as explained in it.

OS#4220
Change-Id: I635c891f5da7b8c59527abbad14d7377465d1045
---
A ttcn3-stp-test/Dockerfile
A ttcn3-stp-test/Makefile
A ttcn3-stp-test/STP_Tests.cfg
A ttcn3-stp-test/jenkins.sh
A ttcn3-stp-test/osmo-stp.cfg
5 files changed, 164 insertions(+), 0 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  pespin: Verified



diff --git a/ttcn3-stp-test/Dockerfile b/ttcn3-stp-test/Dockerfile
new file mode 100644
index 0000000..7e671b3
--- /dev/null
+++ b/ttcn3-stp-test/Dockerfile
@@ -0,0 +1,40 @@
+ARG	USER
+FROM	$USER/debian-stretch-titan
+
+RUN	mkdir /root/projects && (cd /root/projects && ln -sf / git)
+RUN	git clone git://git.osmocom.org/osmo-ttcn3-hacks.git
+
+# FIXME: Once M3UA dep update patches in laforge/stp is merged into master, the
+# line checking it out can be removed.
+RUN	cd osmo-ttcn3-hacks && \
+	git checkout -f -B master origin/master && \
+	git fetch && git checkout -f -B laforge/stp origin/laforge/stp && \
+	make deps
+
+RUN	git config --global user.email docker at dock.er && \
+	git config --global user.name "Dock Er"
+
+# FIXME: Once STP patches in laforge/stp are merged into master, then
+# OSMO_TTCN3_BRANCH can be set again to "master".
+ARG	OSMO_TTCN3_BRANCH="laforge/stp"
+
+ADD	http://git.osmocom.org/osmo-ttcn3-hacks/patch?h=$OSMO_TTCN3_BRANCH /tmp/commit
+RUN	cd osmo-ttcn3-hacks && \
+	git fetch && \
+	git checkout $OSMO_TTCN3_BRANCH && \
+	(git symbolic-ref -q HEAD && git reset --hard origin/$OSMO_TTCN3_BRANCH || exit 1); \
+	git rev-parse --abbrev-ref HEAD && git rev-parse HEAD && \
+	make stp
+
+VOLUME	/data
+
+RUN	ln -s /osmo-ttcn3-hacks/ttcn3-tcpdump-start.sh / && \
+	ln -s /osmo-ttcn3-hacks/ttcn3-tcpdump-stop.sh /
+
+COPY	STP_Tests.cfg /data/STP_Tests.cfg
+
+CMD	cd /data && \
+	/osmo-ttcn3-hacks/start-testsuite.sh /osmo-ttcn3-hacks/stp/STP_Tests; \
+	exit_code=$?; \
+	/osmo-ttcn3-hacks/log_merge.sh STP_Tests --rm; \
+	exit $exit_code
diff --git a/ttcn3-stp-test/Makefile b/ttcn3-stp-test/Makefile
new file mode 100644
index 0000000..cbcd544
--- /dev/null
+++ b/ttcn3-stp-test/Makefile
@@ -0,0 +1,3 @@
+RUN_ARGS?=--sysctl net.ipv6.conf.all.disable_ipv6=0 --rm --network sigtran --ip 172.18.2.202 -v ggsn-test-vol:/data
+
+include ../make/Makefile
diff --git a/ttcn3-stp-test/STP_Tests.cfg b/ttcn3-stp-test/STP_Tests.cfg
new file mode 100644
index 0000000..f41aded
--- /dev/null
+++ b/ttcn3-stp-test/STP_Tests.cfg
@@ -0,0 +1,20 @@
+[ORDERED_INCLUDE]
+"/osmo-ttcn3-hacks/Common.cfg"
+"/osmo-ttcn3-hacks/stp/STP_Tests.default"
+
+[LOGGING]
+*.JUnitLogger.testsuite_name := "STP_Tests"
+
+[TESTPORT_PARAMETERS]
+*.VTY.CTRL_HOSTNAME := "172.18.19.200"
+
+[MODULE_PARAMETERS]
+STP_Tests_Common.mp_stp_ip := "172.18.19.200";
+STP_Tests_Common.mp_local_ip := "172.18.19.203";
+
+
+
+[MAIN_CONTROLLER]
+
+[EXECUTE]
+STP_Tests.control
diff --git a/ttcn3-stp-test/jenkins.sh b/ttcn3-stp-test/jenkins.sh
new file mode 100755
index 0000000..7bb0337
--- /dev/null
+++ b/ttcn3-stp-test/jenkins.sh
@@ -0,0 +1,37 @@
+#!/bin/sh
+
+. ../jenkins-common.sh
+IMAGE_SUFFIX="${IMAGE_SUFFIX:-master}"
+docker_images_require \
+	"debian-stretch-build" \
+	"osmo-stp-$IMAGE_SUFFIX" \
+	"debian-stretch-titan" \
+	"ttcn3-stp-test"
+
+mkdir $VOL_BASE_DIR/stp-tester
+cp STP_Tests.cfg $VOL_BASE_DIR/stp-tester/
+
+mkdir $VOL_BASE_DIR/stp
+cp osmo-stp.cfg $VOL_BASE_DIR/stp/
+
+network_create 172.18.19.0/24
+
+echo Starting container with STP
+docker run	--rm \
+		--network $NET_NAME --ip 172.18.19.200 \
+		-v $VOL_BASE_DIR/stp:/data \
+		--name ${BUILD_TAG}-stp -d \
+		$REPO_USER/osmo-stp-$IMAGE_SUFFIX
+
+echo Starting container with STP testsuite
+docker run	--rm \
+		--network $NET_NAME --ip 172.18.19.203 \
+		-e "TTCN3_PCAP_PATH=/data" \
+		-v $VOL_BASE_DIR/stp-tester:/data \
+		--name ${BUILD_TAG}-ttcn3-stp-test \
+		$REPO_USER/ttcn3-stp-test
+
+docker container kill ${BUILD_TAG}-stp
+
+network_remove
+collect_logs
diff --git a/ttcn3-stp-test/osmo-stp.cfg b/ttcn3-stp-test/osmo-stp.cfg
new file mode 100644
index 0000000..e16cd8b
--- /dev/null
+++ b/ttcn3-stp-test/osmo-stp.cfg
@@ -0,0 +1,64 @@
+!
+! OsmoSTP (1.1.0.2-3884) configuration saved from vty
+!!
+!
+log stderr
+ logging filter all 1
+ logging color 1
+ logging print category-hex 1
+ logging print category 1
+ logging timestamp 0
+ logging print file 1
+ 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
+ logging level ljibuf notice
+ logging level lrspro notice
+!
+stats interval 5
+!
+line vty
+ no login
+ bind 0.0.0.0
+!
+cs7 instance 0
+ point-code format 24
+ asp asp-sender 9999 2905 m3ua
+  local-ip 172.18.19.200
+  remote-ip 172.18.19.203
+ asp asp-receiver0 10000 2905 m3ua
+  local-ip 172.18.19.200
+  remote-ip 172.18.19.203
+ asp asp-receiver1 10001 2905 m3ua
+  local-ip 172.18.19.200
+  remote-ip 172.18.19.203
+ as as-sender m3ua
+  asp asp-sender
+  routing-key 1023 23
+ as as-receiver m3ua
+  asp asp-receiver0
+  routing-key 1042 42
+ as mahlzeit ipa
+  routing-key 0 5
+  point-code override dpc 23
+ route-table system
+  update route 23 16777215 linkset as-sender
+  update route 42 16777215 linkset as-receiver
+ listen m3ua 2905
+  accept-asp-connections dynamic-permitted
+ listen ipa 5000
+  accept-asp-connections dynamic-permitted

-- 
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/15872
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: I635c891f5da7b8c59527abbad14d7377465d1045
Gerrit-Change-Number: 15872
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20191029/74c287b8/attachment.htm>


More information about the gerrit-log mailing list