add db seed
This commit is contained in:
parent
d06b724690
commit
95c716f678
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
$config = array();
|
$config = array();
|
||||||
|
|
||||||
$config['db_dsnw'] = '{{getenv "DATABASEDSN"}}';
|
$config['db_dsnw'] = 'pgsql://{{getenv "DBUSER"}}:{{getenv "DBPASSWORD"}}@{{getenv "DBHOST"}}/DBNAME';
|
||||||
$config['log_driver'] = 'syslog';
|
$config['log_driver'] = 'syslog';
|
||||||
|
|
||||||
$config['default_host'] = '{{getenv "IMAPHOST"}}';
|
$config['default_host'] = '{{getenv "IMAPHOST"}}';
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
#!/usr/bin/with-contenv sh
|
#!/usr/bin/with-contenv sh
|
||||||
|
|
||||||
#PGPASSWORD=$DBPASSWORD psql -h $DBHOST -U $DBUSER -d $DBNAME -c "SELECT EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'nc_appconfig')" | grep f
|
PGPASSWORD=$DBPASSWORD psql -h $DBHOST -U $DBUSER -d $DBNAME -c "SELECT EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'session')" | grep f
|
||||||
|
|
||||||
if [ $? -ne 1 ]; then
|
if [ $? -ne 1 ]; then
|
||||||
|
PGPASSWORD=$DBPASSWORD psql -h $DBHOST -U $DBUSER -d $DBNAME -f /var/lib/roundcube/SQL/postgres.initial.sql
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user