24
24
# Update the data in the configuration file
25
25
juju-log "Updating configuration file"
26
sed -i -e "s/^\\\$THINKUP_CFG\['db_host'\](\s*)\=.*/\$THINKUP_CFG['db_host']$1= '${DB_HOST}';/" -e "s/^\\\$THINKUP_CFG\['db_user'\](\s*)\=.*/\$THINKUP_CFG['db_user']$1= '${DB_USER}';/" -e "s/^\\\$THINKUP_CFG\['db_password'\](\s*)\=.*/\$THINKUP_CFG['db_password']$1= '${DB_PASS}';/" -e "s/^\\\$THINKUP_CFG\['db_name'\](\s*)\=.*/\$THINKUP_CFG['db_name']$1= '${DATABASE}';/" /var/www/config.inc.php
28
33
# Execute the SQL that creates the tables
29
34
juju-log "Creating database tables"