blob: 0127bf851f14c8ad8437d8aa5a8741aa0d678a7f [file] [log] [blame]
Serge Bazanski8d7843c2018-10-04 10:37:36 +01001syntax = "proto3";
2
Sergiusz Bazanski838cf652019-07-16 23:31:25 +02003package topo;
Sergiusz Bazanski61594bb2019-07-21 15:20:51 +02004option go_package = "code.hackerspace.pl/hscloud/dc/topo/proto";
Serge Bazanski477ffe72018-10-25 05:36:18 -07005
Serge Bazanski8d7843c2018-10-04 10:37:36 +01006message Config {
7 repeated Switch switch = 1;
Serge Bazanski9709eef2018-10-05 16:34:28 -07008 repeated Machine machine = 2;
Serge Bazanski8d7843c2018-10-04 10:37:36 +01009};
10
11message Switch {
12 string name = 1;
Serge Bazanski16e4ba22018-10-07 00:22:52 +010013 string control_address = 2;
Serge Bazanski9709eef2018-10-05 16:34:28 -070014 message SwitchPort {
15 string name = 1;
16 };
Serge Bazanski16e4ba22018-10-07 00:22:52 +010017 repeated SwitchPort managed_port = 3;
Serge Bazanski9709eef2018-10-05 16:34:28 -070018 message Segment {
19 enum Type {
20 TYPE_INVALID = 0;
21 TYPE_VLAN = 1;
22 }
23 Type segment_type = 1;
24 int32 vlan_id = 2;
25 };
Serge Bazanski16e4ba22018-10-07 00:22:52 +010026 repeated Segment available_segment = 4;
Serge Bazanski8d7843c2018-10-04 10:37:36 +010027};
28
Serge Bazanski9709eef2018-10-05 16:34:28 -070029message Machine {
Serge Bazanski8d7843c2018-10-04 10:37:36 +010030 string name = 1;
Serge Bazanski9709eef2018-10-05 16:34:28 -070031 message Port {
32 string name = 1;
33 };
34 repeated Port managed_port = 2;
Serge Bazanski8d7843c2018-10-04 10:37:36 +010035};