Commit 2201bb19 authored by Natanael Copa's avatar Natanael Copa

main/postgresql: check if data directory is empty on setup

parent 4e336ad7
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=postgresql
pkgver=8.4.1
pkgrel=0
pkgrel=1
pkgdesc="A sophisticated object-relational DBMS"
url="http://www.postgresql.org/"
license="BSD"
......@@ -47,5 +47,5 @@ client() {
md5sums="f2015af17bacbbfe140daf0d1067f9c9 postgresql-8.4.1.tar.bz2
e4b13053dcbebdf2e59450b94bc27705 postgresql.initd
794aa5e0ee00e6939505aeff527550c2 postgresql.initd
6218755fde294b7d17b77d280a9c9106 postgresql.confd"
......@@ -98,6 +98,7 @@ reload() {
setup() {
ebegin "Creating a new PostgreSQL database cluster"
rmdir "${PGDATA}" 2>/dev/null
if [ -d "${PGDATA}" ] ; then
eend 1 "${PGDATA} already exist"
return
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment