Creating users from shell or perl script

Поиск
Список
Период
Сортировка
От Danny Aldham
Тема Creating users from shell or perl script
Дата
Msg-id 200111230329.fAN3Tda24406@lennon.postino.com
обсуждение исходный текст
Ответы Re: Creating users from shell or perl script  (Oliver Elphick <olly@lfix.co.uk>)
Список pgsql-novice
I have written a program that will install some software,
create a database, and create a couple of postgres users. Most
everything is working, but I cannot see how to create postgres
users with set passwords. If the script calls createuser the
prompts do not come to the user, and anyway I do not want them to.
I want to be able to create the user with a password and not have
the person running the script see it. Right now I am trying in perl:
$output = `/usr/local/pgsql/bin/createuser $New_User ` ;

I have tried attaching using DBI but don't know what DB to attach to.

Any hints or tips appreciated.

--
Danny Aldham     Providing Certified Internetworking Solutions to Business
www.postino.com  E-Mail, Web Servers, Web Databases, SQL PHP & Perl

В списке pgsql-novice по дате отправления:

Предыдущее
От: Francisco Reyes
Дата:
Сообщение: Sizing a box for PostgreSQL
Следующее
От: Oliver Elphick
Дата:
Сообщение: Re: Creating users from shell or perl script