Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
controller
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TFS
controller
Merge requests
!321
Resolve: "(CTTC) CAMARA Demo Integration tests"
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Resolve: "(CTTC) CAMARA Demo Integration tests"
camara-demo-integration
into
develop
Overview
0
Commits
76
Pipelines
34
Changes
1
Merged
Lluis Gifre Renom
requested to merge
camara-demo-integration
into
develop
1 month ago
Overview
0
Commits
76
Pipelines
34
Changes
1
Expand
Closes
#250 (closed)
0
0
Merge request reports
Viewing commit
41efb8cd
Prev
Next
Show latest version
1 file
+
5
−
5
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
41efb8cd
debug: kpi gitlab-ci process deactivated
· 41efb8cd
Shayan Hajipour
authored
1 month ago
src/tests/ofc25-camara-agg-net-controller/.gitlab-ci.yml
0 → 100644
+
90
−
0
Options
# Copyright 2022-2025 ETSI SDG TeraFlowSDN (TFS) (https://tfs.etsi.org/)
#
# Licensed under the Apache License, Version 2.0 (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.apache.org/licenses/LICENSE-2.0
#
# 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.
# Deploy TeraFlowSDN and Execute end-2-end test
end2end_test ofc25_camara_agg_net
:
variables
:
TEST_NAME
:
'
ofc25-camara-agg-net-controller'
IP_NAME
:
'
ip'
IP_PORT
:
'
9092'
stage
:
end2end_test
# Disable to force running it after all other tasks
before_script
:
-
docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
-
HOST_IP=$(kubectl get nodes -o json | jq -r '.items[].status.addresses[] | select(.type=="InternalIP") | .address')
-
sed -i "s/IP_NET_IP/${HOST_IP}/g" src/tests/${TEST_NAME}/data/agg-net-descriptor.json
-
sed -i "s/IP_NET_PORT/${IP_PORT}/g" src/tests/${TEST_NAME}/data/agg-net-descriptor.json
-
docker buildx build -t "${TEST_NAME}:latest" -f ./src/tests/${TEST_NAME}/Dockerfile .
-
docker buildx build -t "${IP_NAME}:latest" -f ./src/tests/tools/mock_ietf_l3vpn_sdn_ctrl/Dockerfile ./src/tests/tools/mock_ietf_l3vpn_sdn_ctrl
-
docker rm -f ${TEST_NAME} ||
true
-
docker rm -f ${IP_NAME} ||
true
-
docker run -d --name ${IP_NAME} -p ${IP_PORT}:8443 ${IP_NAME}:latest
script
:
# Check MicroK8s is ready
-
microk8s status --wait-ready
-
kubectl get pods --all-namespaces
-
source src/tests/${TEST_NAME}/deploy_specs.sh
# Deploy TeraFlowSDN
-
./deploy/crdb.sh
-
./deploy/nats.sh
-
./deploy/qdb.sh
-
./deploy/kafka.sh
-
./deploy/tfs.sh
-
./deploy/show.sh
-
kubectl --namespace $TFS_K8S_NAMESPACE logs deployment/contextservice -c server
# Run end-to-end test: onboard scenario
-
>
docker run -t --rm --name ${TEST_NAME} --network=host
--volume "$PWD/tfs_runtime_env_vars.sh:/var/teraflow/tfs_runtime_env_vars.sh"
--volume "$PWD/src/tests/${TEST_NAME}:/opt/results"
${TEST_NAME}:latest /var/teraflow/run-onboarding.sh
# Run end-to-end test: configure service TFS
-
>
docker run -t --rm --name ${TEST_NAME} --network=host
--volume "$PWD/tfs_runtime_env_vars.sh:/var/teraflow/tfs_runtime_env_vars.sh"
--volume "$PWD/src/tests/${TEST_NAME}:/opt/results"
${TEST_NAME}:latest /var/teraflow/run-agg-net-ietf-slice-operations.sh
after_script
:
-
kubectl --namespace tfs logs deployment/contextservice -c server
-
kubectl --namespace tfs logs deployment/deviceservice -c server
-
kubectl --namespace tfs logs deployment/pathcompservice -c frontend
-
kubectl --namespace tfs logs deployment/serviceservice -c server
-
kubectl --namespace tfs logs deployment/sliceservice -c server
-
kubectl --namespace tfs logs deployment/nbiservice -c server
-
docker logs ${IP_NAME}
# Destroy Scenario
-
kubectl delete namespaces tfs ||
true
-
docker rm -f ${TEST_NAME} ||
true
-
docker rm -f ${IP_NAME} ||
true
# Clean old docker images
-
docker images --filter="dangling=true" --quiet | xargs -r docker rmi
#coverage: '/TOTAL\s+\d+\s+\d+\s+(\d+%)/'
rules
:
-
if
:
'
$CI_PIPELINE_SOURCE
==
"merge_request_event"
&&
($CI_MERGE_REQUEST_TARGET_BRANCH_NAME
==
"develop"
||
$CI_MERGE_REQUEST_TARGET_BRANCH_NAME
==
$CI_DEFAULT_BRANCH)'
-
if
:
'
$CI_PIPELINE_SOURCE
==
"push"
&&
$CI_COMMIT_BRANCH
==
"develop"'
artifacts
:
when
:
always
reports
:
junit
:
./src/tests/${TEST_NAME}/report_*.xml
Loading