Blame tests/p_postgresql/1-config-postgresql.sh
|
Athmane Madjoudj |
e7a36a |
#!/bin/bash
|
|
Athmane Madjoudj |
e7a36a |
# Author: Athmane Madjoudj <athmanem@gmail.com>
|
|
Christoph Galuschka |
6461f0 |
|
|
Christoph Galuschka |
6461f0 |
t_Log "Running $0 - initializing and starting PostgreSQL"
|
|
Athmane Madjoudj |
e7a36a |
|
|
Borislav Andric |
d7cea1 |
t_Log "Initialize PostgreSQL DB "
|
|
Adam Saleh |
b739f5 |
if [ $centos_ver -ge 8 ] then
|
|
Pablo Greco |
ac5fc7 |
postgresql-setup --initdb
|
|
Pablo Greco |
ac5fc7 |
elif (t_GetPkgRel postgresql | grep -q el7) then
|
|
Borislav Andric |
d7cea1 |
postgresql-setup initdb
|
|
Pablo Greco |
ac5fc7 |
elif (t_GetPkgRel postgresql | grep -q el6) then
|
|
Athmane Madjoudj |
e7a36a |
service postgresql initdb
|
|
Borislav Andric |
d7cea1 |
fi
|
|
Borislav Andric |
d7cea1 |
|
|
Borislav Andric |
d7cea1 |
t_ServiceControl postgresql start
|
|
Borislav Andric |
d7cea1 |
sleep 15
|
|
Borislav Andric |
d7cea1 |
|
|
Borislav Andric |
d7cea1 |
|
|
Borislav Andric |
d7cea1 |
|