#!/bin/bash

### Include ymclibnettools
. /usr/lib/lib-fliwi/ymc-networktools.bash

### Remove existing bridge-helpers
for link in $(find /usr/share/fliwi-vhost/helpers/ -mindepth 1 -maxdepth 1 -type l)
do
  if [ -L "$link" ]; then
    rm -f $link
  fi
done

for found_network in $(ymc_get_all_networks_from_dns)
do
  ln -s /usr/share/fliwi-vhost/helpers/multicall_network_starter.bash /usr/share/fliwi-vhost/helpers/$found_network
done

