Skip to content
Snippets Groups Projects
Commit 93e29e7f authored by Elian Loraux's avatar Elian Loraux
Browse files

update loaded env file and prompte for update file

parent 22e54a82
No related branches found
No related tags found
1 merge request!17Reorganisation
#!/bin/bash #!/bin/bash
echo "============= $(basename "$0") =================" echo "RUN $(basename "$0") ==="
if [ ! -e $(pwd)/$(dirname "$0")/../main.env ] if [ ! -e $(dirname "$0")/../main.env ]
then then
echo "Please copy in racine of NoCloud Auto Installer main.env.sample to main.env and edit it" echo "Please copy in racine of NoCloud Auto Installer main.env.sample to main.env and edit it"
exit 1 exit 1
else
echo "Environment file loaded"
fi fi
. $(pwd)/$(dirname "$0")/../main.env . $(dirname "$0")/../main.env
SCRIPT_DIRECTORY=$(dirname $0) SCRIPT_DIRECTORY=$(dirname $0)
if [ -z "$(grep 'capabilities' /etc/apache2/sites-available/collabora.conf)" ]; then if [ -z "$(grep 'capabilities' /etc/apache2/sites-available/collabora.conf)" ]; then
......
...@@ -16,14 +16,16 @@ ...@@ -16,14 +16,16 @@
# You should have received a copy of the GNU General Public License # You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>. # along with this program. If not, see <http://www.gnu.org/licenses/>.
echo "============= $(basename "$0") =================" echo "RUN $(basename "$0") ==="
if [ ! -e $(pwd)/$(dirname "$0")/../main.env ] if [ ! -e $(dirname "$0")/../main.env ]
then then
echo "Please copy in racine of NoCloud Auto Installer main.env.sample to main.env and edit it" echo "Please copy in racine of NoCloud Auto Installer main.env.sample to main.env and edit it"
exit 1 exit 1
else
echo "Environment file loaded"
fi fi
. $(pwd)/$(dirname "$0")/../main.env . $(dirname "$0")/../main.env
DOLIBARR_DB=${DOLIBARR_DB:-"dolibarr"} DOLIBARR_DB=${DOLIBARR_DB:-"dolibarr"}
if [ -z "`dpkg -l | grep dolibarr`" ] if [ -z "`dpkg -l | grep dolibarr`" ]
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
# You should have received a copy of the GNU General Public License # You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>. # along with this program. If not, see <http://www.gnu.org/licenses/>.
echo "============= $(basename "$0") =================" echo "RUN $(basename "$0") ==="
NEXTCLOUD_INSTALL_DIR=${NEXTCLOUD_INSTALL_DIR:-'/var/www/nextcloud'} NEXTCLOUD_INSTALL_DIR=${NEXTCLOUD_INSTALL_DIR:-'/var/www/nextcloud'}
NEXTCLOUD_INSTALL_DIR=`echo $NEXTCLOUD_INSTALL_DIR | sed 's@/*$@@'` NEXTCLOUD_INSTALL_DIR=`echo $NEXTCLOUD_INSTALL_DIR | sed 's@/*$@@'`
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
# You should have received a copy of the GNU General Public License # You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>. # along with this program. If not, see <http://www.gnu.org/licenses/>.
echo "============= $(basename "$0") =================" echo "RUN $(basename "$0") ==="
OLD=$PWD OLD=$PWD
DIR="$OLD/Tetras-back" DIR="$OLD/Tetras-back"
......
#!/bin/bash #!/bin/bash
echo "============= $(basename "$0") =================" echo "=== RUN $(basename "$0") ==="
# Services maintenance # Services maintenance
cd /home/dockerweb cd /home/dockerweb
......
#!/bin/bash #!/bin/bash
echo "============= $(basename "$0") =================" echo "RUN $(basename "$0") ==="
if [ ! -e $(pwd)/$(dirname "$0")/../main.env ] if [ ! -e $(dirname "$0")/../main.env ]
then then
echo "Please copy in racine of NoCloud Auto Installer main.env.sample to main.env and edit it" echo "Please copy in racine of NoCloud Auto Installer main.env.sample to main.env and edit it"
exit 1 exit 1
else
echo "Environment file loaded"
fi fi
. $(pwd)/$(dirname "$0")/../main.env . $(dirname "$0")/../main.env
# Switch to php-fpm # Switch to php-fpm
ver=$(php --version | awk '{print $2}' | head -n 1 | cut -d . -f 1,2) ver=$(php --version | awk '{print $2}' | head -n 1 | cut -d . -f 1,2)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment