On Thu, Jan 16, 2003 at 09:24:47AM -0800, Caffeinate The World wrote:
> --- Witaly Kurakolov <[EMAIL PROTECTED]> wrote:
> >
> > I'm sorry for an error in a patch.
> > In fact only 3 files have been modified.
> [...]
>
> to be complete it should have a
>
> maildroppgsql.config
>
> file?
>
See sample courier configuration files and SQL script
in attach
--
Witaly Kurakolov
DROP VIEW maildrop;
DROP TABLE passwd;
CREATE TABLE passwd (
id varchar(128) NOT NULL default '',
uid numeric(10) NOT NULL default '65534',
gid numeric(10) NOT NULL default '3000',
crypt varchar(128) NOT NULL default '',
clear varchar(128) NOT NULL default '',
name varchar(128) NOT NULL default '',
home varchar(255) NOT NULL default '',
maildir varchar(255) NOT NULL default '',
quota nimeric(10) NOT NULL default '',
PRIMARY KEY (id)
);
CREATE VIEW maildrop
AS SELECT
id AS uid,
uid AS uidnumber,
gid AS gidnumber,
maildir AS maildir,
home AS homedir,
quota AS quota,
'' AS vmailstatus
FROM passwd;
##VERSION: $Id: authpgsqlrc,v 1.3 2002/07/07 05:19:45 mrsam Exp $
#
# Copyright 2000-2001 Double Precision, Inc. See COPYING for
# distribution information.
#
# Do not alter lines that begin with ##, they are used when upgrading
# this configuration.
#
# authpgsqlrc created from authpgsqlrc.dist by sysconftool
#
# DO NOT INSTALL THIS FILE with world read permissions. This file
# might contain the PostgreSQL admin password!
#
# Each line in this file must follow the following format:
#
# field[spaces|tabs]value
#
# That is, the name of the field, followed by spaces or tabs, followed by
# field value. Trailing spaces are prohibited.
##NAME: LOCATION:0
#
# The server hostname, port, userid, and password used to log in.
#
# To connect to a filesystem socket, delete PGSQL_HOST, and set PGSQL_PORT to
# the socket's last component. So, if your pg socket is /tmp/.s.PGSQL.5400
# set PGSQL_PORT to 5400.
PGSQL_HOST localhost
PGSQL_USERNAME xxxxxx
PGSQL_PASSWORD xxxxxx
PGSQL_PORT 5432
##NAME: PGSQL_OPT:0
#
# PGSQL_OPT specifies the connection debug options to PQsetdbLogin().
# Don't bother with this setting unless you know what you're doing
#
# PGSQL_OPT
PGSQL_OPT
##NAME: PGSQL_DATABASE:0
#
# The name of the PgSQL database we will open:
PGSQL_DATABASE mail
##NAME: PGSQL_USER_TABLE:0
#
# The name of the table containing your user data. See README.authmysqlrc
# for the required fields in this table (both MySQL and Postgress use the
# same suggested layout.
PGSQL_USER_TABLE passwd
##NAME: PGSQL_CRYPT_PWFIELD:0
#
# Either PGSQL_CRYPT_PWFIELD or PGSQL_CLEAR_PWFIELD must be defined. Both
# are OK too. crypted passwords go into PGSQL_CRYPT_PWFIELD, cleartext
# passwords go into PGSQL_CLEAR_PWFIELD. Cleartext passwords allow
# CRAM-MD5 authentication to be implemented.
PGSQL_CRYPT_PWFIELD crypt
##NAME: PGSQL_CLEAR_PWFIELD:0
#
#
# PGSQL_CLEAR_PWFIELD clear
##NAME: PGSQL_DEFAULT_DOMAIN:0
#
# If DEFAULT_DOMAIN is defined, and someone tries to log in as 'user',
# we will look up 'user@DEFAULT_DOMAIN' instead.
#
#
# DEFAULT_DOMAIN example.com
##NAME: PGSQL_UID_FIELD:0
#
# Other fields in the mysql table:
#
# PGSQL_UID_FIELD - contains the numerical userid of the account
#
PGSQL_UID_FIELD uid
##NAME: PGSQL_GID_FIELD:0
#
# Numerical groupid of the account
PGSQL_GID_FIELD gid
##NAME: PGSQL_LOGIN_FIELD:0
#
# The login id, default is id. Basically the query is:
#
# SELECT PGSQL_UID_FIELD, PGSQL_GID_FIELD, ... WHERE id='loginid'
#
PGSQL_LOGIN_FIELD id
##NAME: PGSQL_HOME_FIELD:0
#
PGSQL_HOME_FIELD home
##NAME: PGSQL_NAME_FIELD:0
#
# The user's name (optional)
PGSQL_NAME_FIELD name
##NAME: PGSQL_MAILDIR_FIELD:0
#
# This is an optional field, and can be used to specify an arbitrary
# location of the maildir for the account, which normally defaults to
# $HOME/Maildir (where $HOME is read from PGSQL_HOME_FIELD).
#
# You still need to provide a PGSQL_HOME_FIELD, even if you uncomment this
# out.
#
PGSQL_MAILDIR_FIELD maildir
##NAME: PGSQL_QUOTA_FIELD:0
#
# Define PGSQL_QUOTA_FIELD to be the name of the field that can optionally
# specify a maildir quota. See README.maildirquota for more information
#
# PGSQL_QUOTA_FIELD quota
##NAME: PGSQL_WHERE_CLAUSE:0
#
# This is optional, PGSQL_WHERE_CLAUSE can be basically set to an arbitrary
# fixed string that is appended to the WHERE clause of our query
#
# PGSQL_WHERE_CLAUSE server='mailhost.example.com'
hostname localhost
dbuser xxxx
dbpw xxxx
port 5432
database mail
dbtable maildrop