This can be rectified by adding -p to the mkdir command, this will create directories both if they do not exist and also does not classify the existence of a directory specified for creation as an error either, allowing the script to run without fault to continue the re-installation process without any additional efforts from the user.
thanks, updated the reinstall check to remove the lua directories in the event that new source is added in the future, and so we know exactly what is in that dir when we rebuild.
Lines https://github.com/hadojae/redonion/blob/master/redonion_bootstrap.sh#L831-L846 account for the option to re-install Suricata, unfortunately the rest of the script not so much which throws exceptions due to already existent directories.
This can be rectified by adding -p to the mkdir command, this will create directories both if they do not exist and also does not classify the existence of a directory specified for creation as an error either, allowing the script to run without fault to continue the re-installation process without any additional efforts from the user.
The two problem lines listed below here: https://github.com/hadojae/redonion/blob/master/redonion_bootstrap.sh#L890 https://github.com/hadojae/redonion/blob/master/redonion_bootstrap.sh#L908