|
|
@ -107,9 +107,8 @@ DOMAIN: foreach my $domain ( keys $conf->{domains} ) { |
|
|
|
if ( scalar $zim_domain_search->entries == 0 ) { |
|
|
|
if ( scalar $zim_domain_search->entries == 0 ) { |
|
|
|
if ( yaml_bool($conf->{domains}->{$domain}->{zimbra}->{create_if_missing}) ) { |
|
|
|
if ( yaml_bool($conf->{domains}->{$domain}->{zimbra}->{create_if_missing}) ) { |
|
|
|
log_info( "Creating domain $domain" ); |
|
|
|
log_info( "Creating domain $domain" ); |
|
|
|
send_zmprov_cmd( "createDomain $domain " . |
|
|
|
send_zmprov_cmd( "createDomain $domain "); |
|
|
|
build_domain_attrs($conf->{domains}->{$domain}) |
|
|
|
send_zmprov_cmd( "modifyDomain $domain " . build_domain_attrs( $conf->{domains}->{$domain} )); |
|
|
|
); |
|
|
|
|
|
|
|
# Now that we have created the domain, lets lookup again |
|
|
|
# Now that we have created the domain, lets lookup again |
|
|
|
$zim_domain_search = search_zim_domain($domain); |
|
|
|
$zim_domain_search = search_zim_domain($domain); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|