Updates the examples to use the new build scripts (except Hula). (#74)

* Added Makefile and topology.jsons for all examples.

* use branch

* Updated MRI exercise (#73)

* Updated MRI exercise

* Updated basic_tunnel.p4 for changes to p4 lang

* updated other examples
This commit is contained in:
Robert Soule
2017-11-03 12:20:44 -07:00
committed by GitHub
parent aa4298859f
commit 09dba5c63d
38 changed files with 133 additions and 235 deletions

View File

@@ -0,0 +1 @@
include ../../utils/Makefile

View File

@@ -90,7 +90,7 @@ parser MyParser(packet_in packet,
************ C H E C K S U M V E R I F I C A T I O N *************
*************************************************************************/
control MyVerifyChecksum(in headers hdr, inout metadata meta) {
control MyVerifyChecksum(inout headers hdr, inout metadata meta) {
apply { }
}

View File

@@ -1,32 +0,0 @@
{
"program": "basic_tunnel.p4",
"language": "p4-16",
"targets": {
"multiswitch": {
"auto-control-plane": true,
"cli": true,
"pcap_dump": true,
"bmv2_log": true,
"links": [["h1", "s1"], ["s1", "s2"], ["s1", "s3"], ["s3", "s2"], ["s2", "h2"], ["s3", "h3"]],
"hosts": {
"h1": {
},
"h2": {
},
"h3": {
}
},
"switches": {
"s1": {
"entries": "s1-commands.txt"
},
"s2": {
"entries": "s2-commands.txt"
},
"s3": {
"entries": "s3-commands.txt"
}
}
}
}
}

View File

@@ -1,5 +0,0 @@
P4APPRUNNER=../../utils/p4apprunner.py
mkdir -p build
tar -czf build/p4app.tgz * --exclude='build'
#cd build
sudo python $P4APPRUNNER p4app.tgz --build-dir ./build

View File

@@ -0,0 +1,16 @@
{
"hosts": [
"h1",
"h2",
"h3"
],
"switches": {
"s1": { "cli_input" : "s1-commands.txt" },
"s2": { "cli_input" : "s2-commands.txt" },
"s3": { "cli_input" : "s3-commands.txt" }
},
"links": [
["h1", "s1"], ["s1", "s2"], ["s1", "s3"],
["s3", "s2"], ["s2", "h2"], ["s3", "h3"]
]
}