add: initial profile.d script
This commit is contained in:
parent
f091cec3cc
commit
aa2728b99c
29
docker-installer-init.sh
Normal file
29
docker-installer-init.sh
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# ################################################### #
|
||||||
|
# this is init script for docker-rootless-install #
|
||||||
|
# it will be placed in /etc/profile.d/ #
|
||||||
|
# and will be executed on first login #
|
||||||
|
# ################################################### #
|
||||||
|
|
||||||
|
mkdir -p "$HOME/scripts"
|
||||||
|
|
||||||
|
GIT_URL="https://gitea.wssk.ru/sk/docker-rootless-install"
|
||||||
|
INSTALLER_SCRIPT="$HOME/scripts/docker-install.sh"
|
||||||
|
FIRST_RUN_FLAG="$HOME/scripts/.docker_installer_first_run_done"
|
||||||
|
|
||||||
|
if [ -f "$FIRST_RUN_FLAG" ]; then
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
curl -s -o "$INSTALLER_SCRIPT" "$GIT_URL/raw/branch/master/docker-install.sh"
|
||||||
|
sleep 3
|
||||||
|
chmod +x "$INSTALLER_SCRIPT"
|
||||||
|
|
||||||
|
whiptail --title "WSSK" --msgbox "\n\
|
||||||
|
📂 О, привет! Добавил тебе скрипт по установке rootless-докера.\n\n\
|
||||||
|
Для запуска выполни:\n\
|
||||||
|
./scripts/docker-install.sh\n\n\
|
||||||
|
Успехов в разработке!" 15 70
|
||||||
|
|
||||||
|
touch "$FIRST_RUN_FLAG"
|
||||||
Loading…
x
Reference in New Issue
Block a user