Skip to content

Commit

Permalink
ci(svi): prefix svi_id with vrf name
Browse files Browse the repository at this point in the history
Signed-off-by: Boris Glimcher <[email protected]>
  • Loading branch information
glimchb committed Aug 31, 2023
1 parent 66f5aae commit 7321610
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -247,20 +247,20 @@ services:
ip link add br-tenant type bridge vlan_default_pvid 0 vlan_filtering 1 vlan_protocol 802.1Q && \
ip link set br-tenant up && \
echo create && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateVrf "{\"vrf_id\" : \"blue\", \"vrf\" : {\"spec\" : { \"loopback_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772418}, \"len\": 24}, \"vtep_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772162}, \"len\": 24} }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateVrf "{\"vrf_id\" : \"green\", \"vrf\" : {\"spec\" : {\"vni\" : 100, \"loopback_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772674}, \"len\": 24}, \"vtep_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772162}, \"len\": 24} }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateVrf "{\"vrf_id\" : \"yellow\", \"vrf\" : {\"spec\" : {\"vni\" : 101, \"loopback_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772930}, \"len\": 24}, \"vtep_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772162}, \"len\": 24} }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni10\", \"logical_bridge\" : {\"spec\" : {\"vni\" : 10, \"vlan_id\": 10 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni20\", \"logical_bridge\" : {\"spec\" : {\"vni\" : 20, \"vlan_id\": 20 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni30\", \"logical_bridge\" : {\"spec\" : {\"vni\" : 30, \"vlan_id\": 30 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni40\", \"logical_bridge\" : {\"spec\" : {\"vni\" : 40, \"vlan_id\": 40 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni50\", \"logical_bridge\" : {\"spec\" : { \"vlan_id\": 50 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateSvi "{\"svi_id\" : \"vlan20\", \"svi\" : {\"spec\" : {\"vrf\": \"//network.opiproject.org/vrfs/blue\", \"logical_bridge\": \"//network.opiproject.org/bridges/vni20\", \"mac_address\" : \"qrvMAAAh\", \"gw_ip_prefix\": [{\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 336860161}, \"len\": 24}] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateSvi "{\"svi_id\" : \"vlan30\", \"svi\" : {\"spec\" : {\"vrf\": \"//network.opiproject.org/vrfs/blue\", \"logical_bridge\": \"//network.opiproject.org/bridges/vni30\", \"mac_address\" : \"qrvMAAAx\", \"gw_ip_prefix\": [{\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 505290241}, \"len\": 24}] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateSvi "{\"svi_id\" : \"vlan40\", \"svi\" : {\"spec\" : {\"vrf\": \"//network.opiproject.org/vrfs/green\", \"logical_bridge\": \"//network.opiproject.org/bridges/vni40\", \"mac_address\" : \"qrvMAABB\", \"gw_ip_prefix\": [{\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 673720321}, \"len\": 24}] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateSvi "{\"svi_id\" : \"vlan50\", \"svi\" : {\"spec\" : {\"vrf\": \"//network.opiproject.org/vrfs/yellow\", \"logical_bridge\": \"//network.opiproject.org/bridges/vni50\", \"mac_address\" : \"qrvMAABR\", \"gw_ip_prefix\": [{\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 842150401}, \"len\": 24}] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateBridgePort "{\"bridge_port_id\" : \"eth1\", \"bridge_port\" : {\"spec\" : {\"mac_address\" : \"qrvMAAAB\", \"ptype\": \"TRUNK\", \"logical_bridges\": [\"//network.opiproject.org/bridges/vni10\", \"//network.opiproject.org/bridges/vni20\", \"//network.opiproject.org/bridges/vni40\"] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateBridgePort "{\"bridge_port_id\" : \"eth2\", \"bridge_port\" : {\"spec\" : {\"mac_address\" : \"qrvMAAAB\", \"ptype\": \"TRUNK\", \"logical_bridges\": [\"//network.opiproject.org/bridges/vni50\"] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateVrf "{\"vrf_id\" : \"blue\", \"vrf\" : {\"spec\" : { \"loopback_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772418}, \"len\": 24}, \"vtep_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772162}, \"len\": 24} }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateVrf "{\"vrf_id\" : \"green\", \"vrf\" : {\"spec\" : {\"vni\" : 100, \"loopback_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772674}, \"len\": 24}, \"vtep_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772162}, \"len\": 24} }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateVrf "{\"vrf_id\" : \"yellow\", \"vrf\" : {\"spec\" : {\"vni\" : 101, \"loopback_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772930}, \"len\": 24}, \"vtep_ip_prefix\": {\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 167772162}, \"len\": 24} }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni10\", \"logical_bridge\" : {\"spec\" : {\"vni\" : 10, \"vlan_id\": 10 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni20\", \"logical_bridge\" : {\"spec\" : {\"vni\" : 20, \"vlan_id\": 20 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni30\", \"logical_bridge\" : {\"spec\" : {\"vni\" : 30, \"vlan_id\": 30 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni40\", \"logical_bridge\" : {\"spec\" : {\"vni\" : 40, \"vlan_id\": 40 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateLogicalBridge "{\"logical_bridge_id\" : \"vni50\", \"logical_bridge\" : {\"spec\" : { \"vlan_id\": 50 }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateSvi "{\"svi_id\" : \"blue-vlan20\", \"svi\" : {\"spec\" : {\"vrf\": \"//network.opiproject.org/vrfs/blue\", \"logical_bridge\": \"//network.opiproject.org/bridges/vni20\", \"mac_address\" : \"qrvMAAAh\", \"gw_ip_prefix\": [{\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 336860161}, \"len\": 24}] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateSvi "{\"svi_id\" : \"blue-vlan30\", \"svi\" : {\"spec\" : {\"vrf\": \"//network.opiproject.org/vrfs/blue\", \"logical_bridge\": \"//network.opiproject.org/bridges/vni30\", \"mac_address\" : \"qrvMAAAx\", \"gw_ip_prefix\": [{\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 505290241}, \"len\": 24}] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateSvi "{\"svi_id\" : \"green-vlan40\", \"svi\" : {\"spec\" : {\"vrf\": \"//network.opiproject.org/vrfs/green\", \"logical_bridge\": \"//network.opiproject.org/bridges/vni40\", \"mac_address\" : \"qrvMAABB\", \"gw_ip_prefix\": [{\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 673720321}, \"len\": 24}] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateSvi "{\"svi_id\" : \"yellow-vlan50\", \"svi\" : {\"spec\" : {\"vrf\": \"//network.opiproject.org/vrfs/yellow\", \"logical_bridge\": \"//network.opiproject.org/bridges/vni50\", \"mac_address\" : \"qrvMAABR\", \"gw_ip_prefix\": [{\"addr\": {\"af\": \"IP_AF_INET\", \"v4_addr\": 842150401}, \"len\": 24}] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateBridgePort "{\"bridge_port_id\" : \"eth1\", \"bridge_port\" : {\"spec\" : {\"mac_address\" : \"qrvMAAAB\", \"ptype\": \"TRUNK\", \"logical_bridges\": [\"//network.opiproject.org/bridges/vni10\", \"//network.opiproject.org/bridges/vni20\", \"//network.opiproject.org/bridges/vni40\"] }} }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 CreateBridgePort "{\"bridge_port_id\" : \"eth2\", \"bridge_port\" : {\"spec\" : {\"mac_address\" : \"qrvMAAAB\", \"ptype\": \"TRUNK\", \"logical_bridges\": [\"//network.opiproject.org/bridges/vni50\"] }} }" && \
echo get && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetVrf "{\"name\" : \"//network.opiproject.org/vrfs/blue\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetVrf "{\"name\" : \"//network.opiproject.org/vrfs/green\" }" && \
Expand All @@ -270,10 +270,10 @@ services:
/entrypoint.sh call --json_input --json_output localhost:50151 GetLogicalBridge "{\"name\" : \"//network.opiproject.org/bridges/vni30\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetLogicalBridge "{\"name\" : \"//network.opiproject.org/bridges/vni40\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetLogicalBridge "{\"name\" : \"//network.opiproject.org/bridges/vni50\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetSvi "{\"name\" : \"//network.opiproject.org/svis/vlan20\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetSvi "{\"name\" : \"//network.opiproject.org/svis/vlan30\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetSvi "{\"name\" : \"//network.opiproject.org/svis/vlan40\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetSvi "{\"name\" : \"//network.opiproject.org/svis/vlan50\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetSvi "{\"name\" : \"//network.opiproject.org/svis/blue-vlan20\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetSvi "{\"name\" : \"//network.opiproject.org/svis/blue-vlan30\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetSvi "{\"name\" : \"//network.opiproject.org/svis/green-vlan40\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetSvi "{\"name\" : \"//network.opiproject.org/svis/yellow-vlan50\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetBridgePort "{\"name\" : \"//network.opiproject.org/ports/eth1\" }" && \
/entrypoint.sh call --json_input --json_output localhost:50151 GetBridgePort "{\"name\" : \"//network.opiproject.org/ports/eth2\" }" && \
echo done'
Expand Down

0 comments on commit 7321610

Please sign in to comment.