From f7ac8653683327aee6f5e825c49f09d751e0c352 Mon Sep 17 00:00:00 2001 From: ivan Date: Wed, 20 Apr 2005 06:41:39 +0000 Subject: [PATCH] add vpopmail defaults to acct_sql export --- FS/FS/part_export/acct_sql.pm | 50 ++++++++++++++++++++++++++++++++----------- FS/FS/svc_acct.pm | 28 ++++++++++++++++++------ 2 files changed, 60 insertions(+), 18 deletions(-) diff --git a/FS/FS/part_export/acct_sql.pm b/FS/FS/part_export/acct_sql.pm index fb0299c52..a4320e491 100644 --- a/FS/FS/part_export/acct_sql.pm +++ b/FS/FS/part_export/acct_sql.pm @@ -18,7 +18,23 @@ tie my %options, 'Tie::IxHash', type => 'textarea', }, 'primary_key' => { label => 'Database primary key' }, + 'crypt' => { label => 'Password encryption', + type=>'select', options=>[qw(crypt md5)], + default=>'crypt', + }, +; + +tie my %vpopmail_map, 'Tie::IxHash', + 'pw_name' => 'username', + 'pw_domain' => 'domain', + 'pw_passwd' => 'crypt_password', + 'pw_uid' => 'uid', + 'pw_gid' => 'gid', + 'pw_gecos' => 'finger', + 'pw_dir' => 'dir', + 'pw_shell' => 'shell', ; +my $vpopmail_map = join('\n', map "$_ $vpopmail_map{$_}", keys %vpopmail_map ); tie my %postfix_courierimap_mailbox_map, 'Tie::IxHash', 'username' => 'email', @@ -46,23 +62,27 @@ my $postfix_courierimap_alias_map = %info = ( 'svc' => 'svc_acct', 'desc' => 'Real-time export of accounts to SQL databases '. - '(Postfix+Courier IMAP, others?)', + '(vpopmail, Postfix+Courier IMAP, others?)', 'options' => \%options, 'nodomain' => '', 'notes' => <
In contrast to sqlmail, this is newer and less well tested, and -currently less flexible. It is intended to export just svc_acct records only, -rather than a single export for svc_acct, svc_forward and svc_domain records, -to export in "default" formats rather than configure the MTA or POP/IMAP server -for a Freeside-specific schema, and possibly to be configured for different -mail server setups through some subclassing rather than options. +

In contrast to sqlmail, this is intended to export just svc_acct +records only, rather than a single export for svc_acct, svc_forward and +svc_domain records, to export in "default" database schemas rather than +configure the MTA or POP/IMAP server for a Freeside-specific schema, and +to be configured for different mail server setups.

Use these buttons for some useful presets: