hotfix(install.sh): ask to re-run install script after docker is installed
This commit is contained in:
parent
92d5a7b6a3
commit
ba3d860176
1 changed files with 6 additions and 6 deletions
|
@ -121,16 +121,12 @@ if ! command -v docker >/dev/null; then
|
||||||
install_docker "${OS}"
|
install_docker "${OS}"
|
||||||
docker_result=$?
|
docker_result=$?
|
||||||
|
|
||||||
if [[ docker_result -eq 0 ]]; then
|
if [[ docker_result -ne 0 ]]; then
|
||||||
echo "Docker installed"
|
|
||||||
else
|
|
||||||
echo "Your system ${OS} is not supported trying with sub_os ${SUB_OS}"
|
echo "Your system ${OS} is not supported trying with sub_os ${SUB_OS}"
|
||||||
install_docker "${SUB_OS}"
|
install_docker "${SUB_OS}"
|
||||||
docker_sub_result=$?
|
docker_sub_result=$?
|
||||||
|
|
||||||
if [[ docker_sub_result -eq 0 ]]; then
|
if [[ docker_sub_result -ne 0 ]]; then
|
||||||
echo "Docker installed"
|
|
||||||
else
|
|
||||||
echo "Your system ${SUB_OS} is not supported please install docker manually"
|
echo "Your system ${SUB_OS} is not supported please install docker manually"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
@ -138,11 +134,15 @@ if ! command -v docker >/dev/null; then
|
||||||
|
|
||||||
# Make sure user is in docker group
|
# Make sure user is in docker group
|
||||||
if ! groups | grep -q '\bdocker\b'; then
|
if ! groups | grep -q '\bdocker\b'; then
|
||||||
|
echo "Adding user to docker group"
|
||||||
sudo usermod -aG docker "$USER"
|
sudo usermod -aG docker "$USER"
|
||||||
|
echo "✓ Docker installed. Please re-run the installation script to continue with the installation. (curl -L https://setup.runtipi.io | bash)"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Reload user groups
|
# Reload user groups
|
||||||
newgrp docker
|
newgrp docker
|
||||||
|
|
||||||
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
function check_dependency_and_install() {
|
function check_dependency_and_install() {
|
||||||
|
|
Loading…
Reference in a new issue