Right now I have a reset configuration script wich is working if i use it to reset the mikrotik router. I wanted to add two scripts wich should be automaticly in the router if I reset it with my reset configuration script. My problem is that it doesn't work with the added script. I couldn't connect with the Router and had to use the default reset. What is wrong with the following code:
Code: Select all
/system script
add dont-require-permissions=yes name=add-Alpine owner=admin policy=\
ftp,reboot,read,write,policy,test,password,sniff,sensitive,romon source="\
\r\
\n/container/add file=disk2/images/linux.tar interface=veth1 root-dir=disk1/docker/linux_root
mounts=linux_data envlist=linux_envs logging=yes;
/system script
add dont-require-permissions=yes name=container-run owner=admin policy=\
ftp,reboot,read,write,policy,test,password,sniff,sensitive,romon source="\
\r\
\n:local myCon do={:put "container"; :return};\r\
\n:local containerlist [$myCon];\r\
\n:put "Docker is running";\r\
\n/container start $containerlist;\r\
\n/container shell $containerlist;\r\
\n/delay 1;\r\
\n/container stop $containerlist;