=== modified file 'zsh-functions/confz_postgresql_init' --- zsh-functions/confz_postgresql_init 2014-06-27 09:43:35 +0000 +++ zsh-functions/confz_postgresql_init 2014-06-27 09:24:35 +0000 @@ -10,23 +10,10 @@ defvar pgdata $vars[data_dir] defvar locale en_US.UTF-8 defvar initdb initdb - defvar initdb_opts '' [[ -d $vars[data_dir] && -d $vars[pgdata] ]] } confz_postgresql_cluster_do() { - mkdir -p $vars[data_dir] $vars[pgdata] || return $? - chown -Rf $vars[owner]: $vars[data_dir] || return $? - chmod 0700 $vars[data_dir] || return $? - su $vars[owner] -c "$vars[initdb] -L ${(qqq)vars[locale]} -D ${(qqq)vars[data_dir]} $vars[initdb_opts]" || return $? - [[ $vars[data_dir] == $vars[pgdata] ]] || mv $vars[data_dir]/*.conf $vars[pgdata]/ -} - -confz_postgresql_cluster_slot_check() { - checkvars slot - require postgresql_cluster \?owner \?locale \?initdb_opts \ - pgdata="/etc/postgresql-$vars[slot]/" \ - data_dir="/var/lib/postgresql/$vars[slot]/data" \ - initdb="/usr/lib/postgresql-$vars[slot]/bin/initdb" + false }