|
|
@ -326,7 +326,7 @@ var swarmlab_wg0_template = `[Interface] |
|
|
|
PersistentKeepalive = 30 |
|
|
|
|
|
|
|
` |
|
|
|
fs.writeFileSync('./hybrid/connect/template-wg0.conf', swarmlab_wg0_template); |
|
|
|
//fs.writeFileSync('./hybrid/connect/template-wg0.conf', swarmlab_wg0_template);
|
|
|
|
fs.writeFileSync('./hybrid/connect/wg0.conf', swarmlab_wg0_template); |
|
|
|
|
|
|
|
var swarmlab_swarm=RES.value.workerkey |
|
|
@ -334,7 +334,7 @@ var swarmlab_swarm_ip=RES.value.swarm_ip |
|
|
|
var swarmlab_swarm_template = ` |
|
|
|
docker swarm join --token ${swarmlab_swarm} ${swarmlab_swarm_ip} |
|
|
|
` |
|
|
|
fs.writeFileSync('./hybrid/connect/template-swarm.sh', swarmlab_swarm_template); |
|
|
|
//fs.writeFileSync('./hybrid/connect/template-swarm.sh', swarmlab_swarm_template);
|
|
|
|
fs.writeFileSync('./hybrid/connect/reload-swarmlab.sh', swarmlab_swarm_template); |
|
|
|
|
|
|
|
|
|
|
@ -372,6 +372,7 @@ fi |
|
|
|
sleep 1 |
|
|
|
swarmlab=$(swarmlab_ifup) |
|
|
|
if [ $swarmlab != 'active' ]; then |
|
|
|
/bin/bash ${mypath}/hybrid/connect/reload-swarmlab.sh |
|
|
|
sleep 5 |
|
|
|
swarmlab1=$(swarmlab_ifup) |
|
|
|
if [ $swarmlab1 != 'active' ]; then |
|
|
|