aboutsummaryrefslogtreecommitdiffstats
path: root/tests/2-nodes-hicn-light.yml
blob: 849432464030a8d0c671016f133e0bc0affdcdbe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
version: "3"
services:
  client:
    container_name: ${TEST_LIGHT}-client
    command:
      - |
        if [ -d /workspace/build-dev ]; then
          sudo ninja -C /workspace/build-dev install
        fi

        tee -a /tmp/hicn-light.conf <<EOF
        add listener udp local0 ${TOPOLOGY_2_NODES_IP_ADDRESS_CLIENT} 9199 eth0
        add connection udp conn0 ${TOPOLOGY_2_NODES_IP_ADDRESS_CLIENT} 9199 ${TOPOLOGY_2_NODES_IP_ADDRESS_SERVER} 9199
        add route conn0 b002::/64 1
        EOF

        rm -f ${FORWARDER_LOG_PATH}

        sudo hicn-light-daemon \
          --daemon \
          --log-file ${FORWARDER_LOG_PATH} \
          --config /tmp/hicn-light.conf

        tail -f /dev/null

  server:
    container_name: ${TEST_LIGHT}-server
    command:
      - |
        if [ -d /workspace/build-dev ]; then
          sudo ninja -C /workspace/build-dev install
        fi

        tee -a /tmp/hicn-light.conf <<EOF
        add listener udp local0 ${TOPOLOGY_2_NODES_IP_ADDRESS_SERVER} 9199 eth0
        add connection udp conn0 ${TOPOLOGY_2_NODES_IP_ADDRESS_SERVER} 9199 ${TOPOLOGY_2_NODES_IP_ADDRESS_CLIENT} 9199
        EOF

        rm -f ${FORWARDER_LOG_PATH}

        sudo hicn-light-daemon \
          --daemon \
          --log-file ${FORWARDER_LOG_PATH} \
          --config /tmp/hicn-light.conf --capacity 0

        sleep 4

        hiperf -q -z hicnlight_module -S -R -B 4000kbps ${RTC_PRODUCER} -P 2 -k ${HMAC_KEY} &
        hiperf -q -z hicnlight_module -S ${RAAQM_PRODUCER}/128 &
        hiperf -q -z hicnlight_module -S ${RAAQM_PRODUCER_NEW}/128 &
        hicn-ping-server -z hicnlight_module -s 0 -n ${PING_PRODUCER}/128 &

        tail -f /dev/null