diff --git a/deploy.sh b/deploy.sh index abd5e14..951c985 100644 --- a/deploy.sh +++ b/deploy.sh @@ -144,7 +144,6 @@ get_country_from_timezone() { oc_installapp() { local appid="$1" docker exec owncloud_server occ market:install $appid - echo "$appid installed for owncloud" } pause_if_enabled() { @@ -344,40 +343,39 @@ cd /opt/stacks git clone https://github.com/trantienloi2404/youtube-downloader.git downloader #adminemail -replace_string_recursive "/opt/stacks" "?adminemail?" $adminemail +replace_string_recursive "/opt/stacks" "?adminemail?" $adminemail > /dev/null #adminpass -replace_string_recursive "/opt/stacks" "?adminpass?" $adminpass +replace_string_recursive "/opt/stacks" "?adminpass?" $adminpass > /dev/null #timezone -replace_string_recursive "/opt/stacks" "?timezone?" $timezone +replace_string_recursive "/opt/stacks" "?timezone?" $timezone > /dev/null #domain -replace_string_recursive "/opt/stacks" "?domain?" $domain +replace_string_recursive "/opt/stacks" "?domain?" $domain > /dev/null #publicip -replace_string_recursive "/opt/stacks" "?publicip?" $publicip +replace_string_recursive "/opt/stacks" "?publicip?" $publicip > /dev/null #localip -replace_string_recursive "/opt/stacks" "?localip?" $localip +replace_string_recursive "/opt/stacks" "?localip?" $localip > /dev/null #ownclouddbpass -replace_string_recursive "/opt/stacks" "?ownclouddbpass?" $ownclouddbpass +replace_string_recursive "/opt/stacks" "?ownclouddbpass?" $ownclouddbpass > /dev/null #ownclouddbrootpass -replace_string_recursive "/opt/stacks" "?ownclouddbrootpass?" $ownclouddbrootpass +replace_string_recursive "/opt/stacks" "?ownclouddbrootpass?" $ownclouddbrootpass > /dev/null #convertxJWT -replace_string_recursive "/opt/stacks" "?convertxJWT?" $convertxJWT +replace_string_recursive "/opt/stacks" "?convertxJWT?" $convertxJWT > /dev/null #bookstackkey -replace_string_recursive "/opt/stacks" "?bookstackkey?" $bookstackkey -#bookstackdbpass -replace_string_recursive "/opt/stacks" "?bookstackdbpass?" $bookstackdbpass +replace_string_recursive "/opt/stacks" "?bookstackkey?" $bookstackkey > /dev/null +replace_string_recursive "/opt/stacks" "?bookstackdbpass?" $bookstackdbpass > /dev/null #bookstackdbrootpass -replace_string_recursive "/opt/stacks" "?bookstackdbrootpass?" $bookstackdbrootpass +replace_string_recursive "/opt/stacks" "?bookstackdbrootpass?" $bookstackdbrootpass > /dev/null #onlyofficeJWT -replace_string_recursive "/opt/stacks" "?onlyofficeJWT?" $onlyofficeJWT +replace_string_recursive "/opt/stacks" "?onlyofficeJWT?" $onlyofficeJWT > /dev/null #domain -replace_string_recursive "/opt/files" "?domain?" $domain +replace_string_recursive "/opt/files" "?domain?" $domain > /dev/null #publicip -replace_string_recursive "/opt/files" "?publicip?" $publicip +replace_string_recursive "/opt/files" "?publicip?" $publicip > /dev/null #localip -replace_string_recursive "/opt/files" "?localip?" $localip +replace_string_recursive "/opt/files" "?localip?" $localip > /dev/null #adminemail -replace_string_recursive "/opt/files" "?adminemail?" $adminemail +replace_string_recursive "/opt/files" "?adminemail?" $adminemail > /dev/null # install mailcow to /opt/stacks/mailcow so it shows up in dockge umask 0022 @@ -403,9 +401,9 @@ echo -e "${cyan}Dockge${nc} has been installed and launched. go to http://$local pause_if_enabled # call replacements for nginx db -replace_in_sqlite_db "/opt/stacks/npm/data/database.sqlite" "" $domain -replace_in_sqlite_db "/opt/stacks/npm/data/database.sqlite" "" $localip -replace_in_sqlite_db "/opt/stacks/npm/data/database.sqlite" "" $publicip +replace_in_sqlite_db "/opt/stacks/npm/data/database.sqlite" "" $domain > /dev/null +replace_in_sqlite_db "/opt/stacks/npm/data/database.sqlite" "" $localip > /dev/null +replace_in_sqlite_db "/opt/stacks/npm/data/database.sqlite" "" $publicip > /dev/null cd /opt/stacks/npm docker compose up -d @@ -441,7 +439,7 @@ echo -e "${cyan}onlyoffice${nc} has been launched from http://office.$domain, ve cd /opt/stacks/owncloud docker compose up -d echo "awaiting owncloud boot" -sleep 120 +sleep 40 oc_installapp bookmarks oc_installapp calendar oc_installapp camerarawpreviews @@ -461,6 +459,7 @@ oc_installapp tasks docker exec owncloud_server occ config:app:set onlyoffice DocumentServerUrl --value="https://office.$domain/" docker exec owncloud_server occ config:app:set onlyoffice jwt_secret --value="$onlyofficeJWT" +docker restart owncloud_server echo -e "${cyan}owncloud${nc} has been launched from http://cloud.$domain, check if it is online and working, it may take a bit to launch. 502 error = still starting" cd /opt/stacks/site @@ -481,24 +480,25 @@ docker compose up -d echo -e "${cyan}wireguard${nc} has been launched from http://vpn.$domain, verify it is online" cd /opt/stacks/downloader -docker compose up -d -echo -e "${cyan}downloader${nc} has been launched from http://download.$domain, verify it is online" +echo "bringing up downloader, this may take a while." echo "" echo -e "recap of all available services up to now:" -echo -e "${cyan}owncloud${nc} has been launched from http://cloud.$domain, check if it is online and working, it may take a bit to launch. feel free to add marketplace plugins" +echo -e "${cyan}owncloud${nc} has been launched from http://cloud.$domain, check if it is online and working." echo -e "${cyan}vaultwarden${nc} has been launched from http://vault.$domain, verify it is online" echo -e "${cyan}site${nc} has been launched from http://www.$domain, verify it is online" echo -e "${cyan}onlyoffice${nc} has been launched from http://tools.$domain, verify it is online" echo -e "${cyan}it-tools${nc} has been launched from http://tools.$domain, verify it is online" echo -e "${cyan}wireguard${nc} has been launched from http://vpn.$domain, verify it is online" echo -e "${cyan}convertx${nc} has been launched from http://convert.$domain, verify it is online" -echo -e "${cyan}downloader${nc} has been launched from http://download.$domain, verify it is online" echo -e "${cyan}dozzle${nc} has been launched from http://dozzle.$domain, verify it is online, do not worry if the UI gives a time-out error, this is due to docker being busy while this script runs." echo -e "${cyan}Nginx Proxy Manager${nc} has been installed, configured and launched from http://proxy.$domain" echo -e "${cyan}Dockge${nc} has been installed, configured and launched from http://docker.$domain" echo -e "${cyan}pihole${nc} has been launched from http://dns.$domain, to use pihole as your DNS provider, set your DNS to $localip in your router for DHCP and on your device for any device with a static ip. Currently, the DNS is configured to use the joindns4.eu DNS, which *also* has built-in adblocking." echo "" echo "you may have to go to settings > additional in owncloud and click "save" for the onlyoffice server settings." +docker compose up -d > /dev/null +echo -e "${cyan}downloader${nc} has been launched from http://download.$domain, verify it is online" + #bookstack cd /opt/stacks/bookstack