set installer base correctly

This commit is contained in:
AJ ONeal 2017-05-25 18:57:24 +00:00
parent 4e0b996acd
commit 66589782fe
1 changed files with 5 additions and 3 deletions

View File

@ -134,6 +134,7 @@ install_for_launchd()
install_etc_config() install_etc_config()
{ {
#echo "install etc config $MY_ROOT / $my_app_etc_config"
if [ ! -e "$MY_ROOT/$my_app_etc_config" ]; then if [ ! -e "$MY_ROOT/$my_app_etc_config" ]; then
$sudo_cmd mkdir -p $(dirname "$MY_ROOT/$my_app_etc_config") $sudo_cmd mkdir -p $(dirname "$MY_ROOT/$my_app_etc_config")
mkdir -p $(dirname "$my_app_dir/$my_app_etc_config") mkdir -p $(dirname "$my_app_dir/$my_app_etc_config")
@ -149,8 +150,8 @@ install_etc_config()
install_service() install_service()
{ {
echo "install etc config"
install_etc_config install_etc_config
#echo "install service"
installable="" installable=""
if [ -d "$MY_ROOT/etc/systemd/system" ]; then if [ -d "$MY_ROOT/etc/systemd/system" ]; then
@ -186,7 +187,7 @@ create_skeleton()
# Unistall # Unistall
install_uninstaller() install_uninstaller()
{ {
echo "install uninstaller" #echo "install uninstaller"
dap_dl "https://git.daplie.com/Daplie/walnut.js/raw/master/uninstall.sh" "./walnut-uninstall" dap_dl "https://git.daplie.com/Daplie/walnut.js/raw/master/uninstall.sh" "./walnut-uninstall"
$sudo_cmd chmod 755 "./walnut-uninstall" $sudo_cmd chmod 755 "./walnut-uninstall"
$sudo_cmd chown root:root "./walnut-uninstall" $sudo_cmd chown root:root "./walnut-uninstall"
@ -204,7 +205,8 @@ my_app_name=walnut
my_app_pkg_name=com.daplie.walnut.web my_app_pkg_name=com.daplie.walnut.web
my_app_dir=$(mktemp -d) my_app_dir=$(mktemp -d)
#installer_base="https://git.daplie.com/Daplie/walnut.js/raw/master/dist" #installer_base="https://git.daplie.com/Daplie/walnut.js/raw/master/dist"
installer_base="./dist" #installer_base="$( dirname "${BASH_SOURCE[0]}" )/dist"
installer_base="/srv/walnut/core/dist"
my_app_etc_config="etc/${my_app_name}/${my_app_name}.yml" my_app_etc_config="etc/${my_app_name}/${my_app_name}.yml"
my_app_systemd_service="etc/systemd/system/${my_app_name}.service" my_app_systemd_service="etc/systemd/system/${my_app_name}.service"