X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fpart_export.pm;h=8423da299a7f238077c2a35c9fe0445e05b59699;hb=c13536bec93ca007d6b339dfbc7edc81ae58c082;hp=d6422fe16fc669c4ecf3e0048ec3d9a2e21157cb;hpb=1db61c35afc546c51de4931ced48330c19af21eb;p=freeside.git
diff --git a/FS/FS/part_export.pm b/FS/FS/part_export.pm
index d6422fe16..8423da299 100644
--- a/FS/FS/part_export.pm
+++ b/FS/FS/part_export.pm
@@ -274,10 +274,6 @@ sub check {
;
return $error if $error;
- $self->machine =~ /^([\w\-\.]*)$/
- or return "Illegal machine: ". $self->machine;
- $self->machine($1);
-
$self->nodomain =~ /^(Y?)$/ or return "Illegal nodomain: ". $self->nodomain;
$self->nodomain($1);
@@ -472,18 +468,22 @@ sub _export_delete {
return "_export_delete: unknown export type ". $self->exporttype;
}
-#fallbacks providing null operations
+#call svcdb-specific fallbacks
sub _export_suspend {
my $self = shift;
#warn "warning: _export_suspened unimplemented for". ref($self);
- '';
+ my $svc_x = shift;
+ my $new = $svc_x->clone_suspended;
+ $self->_export_replace( $new, $svc_x );
}
sub _export_unsuspend {
my $self = shift;
#warn "warning: _export_unsuspend unimplemented for ". ref($self);
- '';
+ my $svc_x = shift;
+ my $old = $svc_x->clone_kludge_unsuspend;
+ $self->_export_replace( $svc_x, $old );
}
=back
@@ -580,13 +580,13 @@ tie my %shellcommands_options, 'Tie::IxHash',
type =>'checkbox',
},
'suspend' => { label=>'Suspension command',
- default=>'',
+ default=>'usermod -L $username',
},
'suspend_stdin' => { label=>'Suspension command STDIN',
default=>'',
},
'unsuspend' => { label=>'Unsuspension command',
- default=>'',
+ default=>'usermod -U $username',
},
'unsuspend_stdin' => { label=>'Unsuspension command STDIN',
default=>'',
@@ -681,7 +681,7 @@ tie my %router_options, 'Tie::IxHash',
;
tie my %domain_shellcommands_options, 'Tie::IxHash',
- 'user' => { lable=>'Remote username', default=>'root' },
+ 'user' => { label=>'Remote username', default=>'root' },
'useradd' => { label=>'Insert command',
default=>'',
},
@@ -702,12 +702,20 @@ tie my %sqlradius_options, 'Tie::IxHash',
'datasrc' => { label=>'DBI data source ' },
'username' => { label=>'Database username' },
'password' => { label=>'Database password' },
+ 'ignore_accounting' => {
+ type => 'checkbox',
+ label=>'Ignore accounting records from this database'
+ },
;
tie my %sqlradius_withdomain_options, 'Tie::IxHash',
'datasrc' => { label=>'DBI data source ' },
'username' => { label=>'Database username' },
'password' => { label=>'Database password' },
+ 'ignore_accounting' => {
+ type => 'checkbox',
+ label=>'Ignore accounting records from this database'
+ },
;
tie my %cyrus_options, 'Tie::IxHash',
@@ -758,6 +766,24 @@ tie my %communigate_pro_options, 'Tie::IxHash',
},
;
+tie my %communigate_pro_singledomain_options, 'Tie::IxHash',
+ 'port' => { label=>'Port number', default=>'106', },
+ 'login' => { label=>'The administrator account name. The name can contain a domain part.', },
+ 'password' => { label=>'The administrator account password.', },
+ 'domain' => { label=>'Domain', },
+ 'accountType' => { label=>'Type for newly-created accounts',
+ type=>'select',
+ options=>[qw( MultiMailbox TextMailbox MailDirMailbox )],
+ default=>'MultiMailbox',
+ },
+ 'externalFlag' => { label=> 'Create accounts with an external (visible for legacy mailers) INBOX.',
+ type=>'checkbox',
+ },
+ 'AccessModes' => { label=>'Access modes',
+ default=>'Mail POP IMAP PWD WebMail WebSite',
+ },
+;
+
tie my %bind_options, 'Tie::IxHash',
#'machine' => { label=>'named machine' },
'named_conf' => { label => 'named.conf location',
@@ -869,7 +895,7 @@ tie my %ldap_options, 'Tie::IxHash',
;
tie my %forward_shellcommands_options, 'Tie::IxHash',
- 'user' => { lable=>'Remote username', default=>'root' },
+ 'user' => { label=>'Remote username', default=>'root' },
'useradd' => { label=>'Insert command',
default=>'',
},
@@ -881,6 +907,13 @@ tie my %forward_shellcommands_options, 'Tie::IxHash',
},
;
+tie my %postfix_options, 'Tie::IxHash',
+ 'user' => { label=>'Remote username', default=>'root' },
+ 'aliases' => { label=>'aliases file location', default=>'/etc/aliases' },
+ 'virtual' => { label=>'virtual file location', default=>'/etc/postfix/virtual' },
+ 'mydomain' => { label=>'local domain', default=>'' },
+;
+
#export names cannot have dashes...
%exports = (
'svc_acct' => {
@@ -913,7 +946,7 @@ tie my %forward_shellcommands_options, 'Tie::IxHash',
'desc' => 'Real-time export via remote SSH (i.e. useradd, userdel, etc.)',
'options' => \%shellcommands_options,
'nodomain' => 'Y',
- 'notes' => 'Run remote commands via SSH. Usernames are considered unique (also see shellcommands_withdomain). You probably want this if the commands you are running will not accept a domain as a parameter. You will need to setup SSH for unattended operation.
Use these buttons for some useful presets:
$username
$_password
$quoted_password
- unencrypted password quoted for the shell$crypt_password
- encrypted password$uid
$gid
$finger
- GECOS, already quoted for the shell (do not add additional quotes)$dir
- home directory$shell
$quota
$username
$_password
$quoted_password
- unencrypted password quoted for the shell$crypt_password
- encrypted password$uid
$gid
$finger
- GECOS, already quoted for the shell (do not add additional quotes)$dir
- home directory$shell
$quota
ALTER TABLE radcheck ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radreply ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radgroupcheck ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radgroupreply ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radcheck ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radreply ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radgroupcheck ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radgroupreply ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radcheck ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radreply ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radgroupcheck ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radgroupreply ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radcheck ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radreply ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radgroupcheck ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
ALTER TABLE radgroupreply ADD COLUMN op VARCHAR(2) NOT NULL DEFAULT \'==\'
new_
or old_
for replace operations): $username
$domain
$destination
- forward destination