Skip to content
Snippets Groups Projects
Commit ab5e5ac6 authored by Felix Ohms's avatar Felix Ohms
Browse files

use complex clab environment for integration tests

parent 6465c55a
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !196. Comments created here will be created in the context of that merge request.
......@@ -42,7 +42,7 @@ variables:
containerlab:template:integration:
extends: .containerlab_template
variables:
CLAB_TEMPLATE: "${CI_PROJECT_DIR}/test/containerlab/int01.clab.tmpl.yml"
CLAB_TEMPLATE: "${CI_PROJECT_DIR}/test/containerlab/complex-1.0.clab.tmpl.yml"
rules:
- if: $CI_PIPELINE_SOURCE == "merge_request_event" && ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME == $CI_DEFAULT_BRANCH || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == 'develop')
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
......@@ -53,12 +53,18 @@ containerlab:deploy:integration:
extends: .containerlab_deploy
needs: ["containerlab:template:integration", "build-docker"]
script:
- cat ${CI_PROJECT_DIR}/${CLAB_NAME}.clab.yml
- sudo containerlab deploy --topo ${CI_PROJECT_DIR}/${CLAB_NAME}.clab.yml --reconfigure
- |
echo -e "\
GOSDN_HTTP_PORT=$(docker_host_port 8080 clab-${CLAB_NAME}-gosdn)\n\
GOSDN_GRPC_PORT=$(docker_host_port 55055 clab-${CLAB_NAME}-gosdn)\n\
CEOS1_PORT=$(docker_host_port 6030 clab-${CLAB_NAME}-ceos1)" \
CEOS1-1_PORT=$(docker_host_port 6030 clab-${CLAB_NAME}-ceos1-1)\n\
CEOS1-2_PORT=$(docker_host_port 6030 clab-${CLAB_NAME}-ceos1-2)\n\
CEOS2-1-1_PORT=$(docker_host_port 6030 clab-${CLAB_NAME}-ceos2-1-1)\n\
CEOS2-1-2_PORT=$(docker_host_port 6030 clab-${CLAB_NAME}-ceos2-1-2)\n\
CEOS2-2-1_PORT=$(docker_host_port 6030 clab-${CLAB_NAME}-ceos2-2-1)\n\
CEOS2-2-2_PORT=$(docker_host_port 6030 clab-${CLAB_NAME}-ceos2-2-2)" \
> ${CI_PROJECT_DIR}/build.env
- cat ${CI_PROJECT_DIR}/build.env
artifacts:
......
# topology documentation: http://containerlab.srlinux.dev/lab-examples/srl-ceos/
name: complex-1.0
name: @@CLAB_NAME@@
mgmt:
network: @@CLAB_NAME@@
ipv4_subnet: @@CLAB_MGMT_SUBNET@@
topology:
nodes:
gosdn:
kind: linux
image: registry.code.fbi.h-da.de/cocsn/gosdn:develop
image: @@GOSDN_CONTAINER_IMAGE@@
ports:
- 0:8080
- 0:55055
ceos1-1:
kind: ceos
image: ceosimage:4.26.0F
image: @@CEOS_CONTAINER_IMAGE@@
ports:
- 0:6030
ceos1-2:
kind: ceos
image: ceosimage:4.26.0F
image: @@CEOS_CONTAINER_IMAGE@@
ports:
- 0:6030
ceos2-1-1:
kind: ceos
image: ceosimage:4.26.0F
image: @@CEOS_CONTAINER_IMAGE@@
ports:
- 0:6030
ceos2-1-2:
kind: ceos
image: ceosimage:4.26.0F
image: @@CEOS_CONTAINER_IMAGE@@
ports:
- 0:6030
ceos2-2-1:
kind: ceos
image: ceosimage:4.26.0F
image: @@CEOS_CONTAINER_IMAGE@@
ports:
- 0:6030
ceos2-2-2:
kind: ceos
image: ceosimage:4.26.0F
image: @@CEOS_CONTAINER_IMAGE@@
ports:
- 0:6030
server3-1-1:
kind: linux
image: alpine:latest
......@@ -39,7 +58,7 @@ topology:
server3-2-2:
kind: linux
image: alpine:latest
links:
- endpoints: ["ceos1-1:eth1", "ceos2-1-1:eth1"]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment