download wsl2-systemd script

This commit is contained in:
2023-07-10 14:53:32 +00:00
parent 5a55963ca6
commit 9bc1445455
2 changed files with 9 additions and 5 deletions

View File

@@ -40,11 +40,11 @@ if [ "$ADDITIONALS" == "true" ]; then
sh /additional_install.sh
echo "Additional install has finished"
elif [ -n "$WSL_DISTRO_NAME" ]; then
echo "WSL2 systemd script has started"
sh /wsl2-systemd-script.sh
#systemctl
echo "WSL2 systemd script has finished"
else
echo "Download WSL2 systemd scripts"
cp -rv /wsl2-systemd-script.sh /usr/local/bin/wsl2-systemd-script.sh
cp -rv /enter-systemd-namespace /usr/local/bin/enter-systemd-namespace
cp -rv /wsl2-systemd-script.sh /usr/local/bin/start-systemd-namespace
else # default install
if [[ "$SMARTHOST_PROXY" == "YES" || "$SMARTHOST_PROXY" == "TRUE" ]]; then
PROXY_TYPE=smarthost-proxy" "$PROXY_TYPE;
fi

View File

@@ -661,8 +661,12 @@ if [ -n "$WSL_DISTRO_NAME" ]; then
--volume $HOME/.ssh/installer:/root/.ssh/id_rsa \
--volume /etc/user/:/etc/user/ \
--volume /etc/system/:/etc/system/ \
--volume /usr/local/bin/:/usr/local/bin/ \
registry.format.hu/installer-tool
fi;
sh /usr/local/bin/wsl2-systemd-script.sh
#systemctl
fi;
shopt -s expand_aliases