Changeset 3369
- Timestamp:
- Jan 19, 2017, 1:41:02 PM (4 years ago)
- Location:
- lliurex-analytics-server/trunk/fuentes/debian
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
lliurex-analytics-server/trunk/fuentes/debian/control
r1132 r3369 9 9 Depends: ${shlibs:Depends}, ${misc:Depends}, 10 10 debconf (>= 0.5) | debconf-2.0, po-debconf, 11 ucf, python3, python-daemon, apache2, libapache2-mod-php7.0, php7.0-mysql, mysql-server, python-requests, dialog 11 ucf, python3, python-daemon, apache2, libapache2-mod-php7.0, php7.0-mysql, mysql-server, python-requests, dialog, perl 12 12 Recommends: 13 13 Suggests: -
lliurex-analytics-server/trunk/fuentes/debian/postinst
r3367 r3369 121 121 echo "user=$user" >> /etc/lliurex-analytics-server/config_db 122 122 echo "pass=$pass" >> /etc/lliurex-analytics-server/config_db 123 chmod 750 /etc/lliurex-analytics-server/config_db 123 124 fi 124 125 $mysqluser < /usr/lib/analytics-server/analytics.sql … … 131 132 echo "user=$user" >> /etc/lliurex-analytics-server/config_db 132 133 echo "pass=$pass" >> /etc/lliurex-analytics-server/config_db 133 134 chmod 640 /etc/lliurex-analytics-server/config_db 134 135 fi 135 136 fi … … 137 138 RES1=$(grep -o '@phpuser@' /usr/lib/analytics-server/analytics/config.php) 138 139 RES2=$(grep -o '@phppass@' /usr/lib/analytics-server/analytics/config.php) 139 140 if [ - n "${RES1}" -a -n "${RES2}" ]; then140 141 if [ -f "/usr/lib/analytics-server/analytics/config.php" -a -n "${RES1}" -a -n "${RES2}" ]; then 141 142 sed -i.old -e "s/@phpuser@/$user/g" -e "s/@phppass@/$pass/g" /usr/lib/analytics-server/analytics/config.php 142 143 rm /usr/lib/analytics-server/analytics/config.php.old 144 chmod 640 /usr/lib/analytics-server/analytics/config.php 145 apachectl_cmd=$(which apachectl) 146 apache_group=$(${apachectl_cmd} -t -D DUMP_RUN_CFG 2>/dev/null|perl -ne '/group:[ ]+name=\"(.*)\"/i && print $1') 147 if [ -z "${apache_group}" ]; then 148 echo "Warning: apache group not detected, falling back to www-data" 149 apache_group="www-data" 150 fi 151 chgrp ${apache_group} /usr/lib/analytics-server/analytics/config.php 143 152 else 144 153 echo "BUG !! WARNING: replace tags @phpuser@ & @phppass@ not found in /usr/lib/analytics-server/analytics/config.php" -
lliurex-analytics-server/trunk/fuentes/debian/postrm
r3366 r3369 62 62 echo "flush privileges;"| ${mysql_cmd} 2>/dev/null 63 63 echo "Database analytics & user ${USER} removed from mysql" 64 if [ -f "/etc/lliurex-analytics-server/config_db" ]; then 65 rm -f /etc/lliurex-analytics-server/config_db 66 rmdir /etc/lliurex-analytics-server 67 else 68 echo "Warning: config_db file not found! " 69 fi 64 70 exit 0 65 71 ;;
Note: See TracChangeset
for help on using the changeset viewer.