Commit 309bcaf5 authored by David Hancock's avatar David Hancock

Move hp4 json path update to correct script

From config.sh (for local host interacting w/ remote cloudlab
nodes, or running a local mininet sim) to start_hp4.sh (runs
on remote cloudlab node, only necessary for node 0 where the
controller runs)
parent b468adca
......@@ -5,7 +5,6 @@ then
echo "configuring controller for cloudlab execution"
printf "#!/bin/bash\n\n" > tests/ssh_vals.sh
printf "user=$1\n" >> tests/ssh_vals.sh
echo "/opt/hp4-src/hp4/hp4.json" > hp4controller/hp4_json_path
if [[ $# -gt 1 ]]
then
printf "nodes=( $2 $3 $4 $5 $6 $7 $8 $9 ${10} ${11} ${12} )\n" >> tests/ssh_vals.sh
......
#!/bin/bash
# update paths in hp4-src/env.sh
# compile hp4
cd /opt/hp4-src
sudo p4c-bmv2 --json hp4/hp4.json hp4/p4src/hp4.p4
# update paths in hp4-src/env.sh
sudo sed -i 's/\/home\/ubuntu/\/opt/g' env.sh
# update hp4 json path, needed by controller
cd /opt/hp4-ctrl
sudo echo "/opt/hp4-src/hp4/hp4.json" > hp4controller/hp4_json_path
cd /opt
script_path=/opt/hp4-ctrl/vibrant-eval/remote-scripts
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment