Install script fixes

main
Yasen Pramatarov 2024-07-19 11:14:30 +03:00
parent 7e5e68dc23
commit 6596e97889
1 changed files with 89 additions and 54 deletions

View File

@ -1,6 +1,8 @@
#!/usr/bin/env bash
echo "Jilo-Web install script"
echo "Jilo-Web deployment script"
function install() {
# enter domain
read -p "Domain name for the web service [localhost]: " DOMAIN
@ -65,3 +67,36 @@ chown -R www-data:www-data "$INSTALL_DIR"
chmod -R ug+rw "$INSTALL_DIR"
echo 'Install finished.'
}
help="Usage:
$0 [OPTION]
Options:
--install|-i - install Jilo-Web
--help|-h - show this help message
--version|-v - show version"
version="Jilo-Web deployment script
version $VERSION"
if [[ $1 ]]; then
case $1 in
-i | --install)
;;
-h | --help)
echo -e "$help"
exit 0
;;
-v | --version)
echo -e "$version"
exit 0
;;
*)
echo "Invalid option: $1" >&2
echo -e "$help"
exit 1
;;
esac
fi