Project

General

Profile

« Previous | Next » 

Revision 6dc2f272

Added by Andreas Kohlbecker almost 3 years ago

fixing bug in update script

View differences:

scripts/admin/update-dependencies.sh
1
#!/bin/bash -x
1
#!/bin/bash
2 2

  
3 3

  
4 4
# -- options
......
7 7
        -h|--help) print_help=1;;
8 8
        --mailto) MAILTO="$2"; shift ;;
9 9
        --deactivate-install) deactivate_install=1 ;;
10
        --multi-site) multi-site=1 ;;
10
        --multi-site) multisite=1 ;;
11 11
        --site-url) site_url=$2; shift ;;
12 12
        *) echo "Unknown parameter passed: $1"; exit 1 ;;
13 13
    esac
......
15 15
done
16 16

  
17 17
if [[ -n "$site_url" ]]; then
18
    unset multi-site
18
    unset multisite
19 19
fi 
20 20

  
21 21
# -- help
......
36 36
fi
37 37

  
38 38
# --- backups before any modification
39
TMP=$(mktemp -d)
40

  
39 41
echo "creating full backup ..."
40 42
archive_file=../drupal-7-cdm-dataportal-backup-$(date -I).tar.gz
41 43
tar -czf $archive_file ./
......
49 51
cp -a web/robots*.txt ${TMP}/
50 52

  
51 53
# -- setup 
52
TMP=$(mktemp -d)
53 54

  
54
if [[ "$multi-site" == "1" ]]; then
55
if [[ "$multisite" == "1" ]]; then
55 56
    DRUSH=$(which dataportals-drush) 
56 57
else 
57 58
    DRUSH=./vendor/drush/drush/drush
......
64 65
DRUSH=$DRUSH" -r $(pwd)/web/" 
65 66
if [[ -n "$site_url" ]]; then
66 67
    DRUSH=$DRUSH" -l $site_url"
67
fi 
68

  
69

  
70
exit 0 
68
fi
71 69

  
72 70
echo "setting dataportals in update mode ..."
73 71
# set all portals into maintenance mode

Also available in: Unified diff