Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F120837785
kolab-mta-join-script.sh
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
2 KB
Referenced Files
None
Subscribers
None
kolab-mta-join-script.sh
View Options
#!/bin/sh
#
# Kolab Systems Mail Postfix Kolab2
# join script
#
# Copyright 2011-2012 Univention GmbH
# 2011-1012 Kolab Systems AG
#
# http://www.kolabsys.com/
#
# All rights reserved.
#
# The source code of this program is made available
# under the terms of the GNU Affero General Public License version 3
# (GNU AGPL V3) as published by the Free Software Foundation.
#
# Binary versions of this program provided by Univention to you as
# well as other copyrighted, protected or trademarked materials like
# Logos, graphics, fonts, specific documentations and configurations,
# cryptographic keys etc. are subject to a license agreement between
# you and Univention and not subject to the GNU AGPL V3.
#
# In the case you use this program under the terms of the GNU AGPL V3,
# the program is provided in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public
# License with the Debian GNU/Linux or Univention distribution in file
# /usr/share/common-licenses/AGPL-3; if not, see
# <http://www.gnu.org/licenses/>.
VERSION
=
3
. /usr/share/univention-lib/all.sh
. /usr/share/univention-join/joinscripthelper.lib
joinscript_init
eval
"
$(
ucr shell
)
"
# add service to my host object
ucs_addServiceToLocalhost
"SMTP"
"
$@
"
# create initial mail domain object(s) if missing
if
! udm mail/domain list
"
$@
"
|
grep -q
"^DN:"
;
then
# no mail domain object found
# Default; create new object with $domainname as mail domain
# can be overridden by mail/default/domains
domain_list
=
"
$domainname
"
if
[
"
$mail_default_domains
"
]
;
then
domain_list
=
"
$mail_default_domains
"
fi
# create required containers
udm container/cn create
"
$@
"
--ignore_exists --position
"
$ldap_base
"
--set
name
=
"mail"
udm container/cn create
"
$@
"
--ignore_exists --position
"cn=mail,
$ldap_base
"
--set
name
=
"domain"
# create new object
for
domain
in
$domain_list
;
do
udm mail/domain create
"
$@
"
--ignore_exists
\
--position
"cn=domain,cn=mail,
$ldap_base
"
\
--set
name
=
"
$domain
"
done
fi
# call server password change script - system was likely not joined before package installation
/usr/lib/univention-server/server_password_change.d/kolab-mta prechange
/usr/lib/univention-server/server_password_change.d/kolab-mta postchange
joinscript_save_current_version
exit
0
File Metadata
Details
Attached
Mime Type
text/x-shellscript
Expires
Fri, Apr 24, 1:50 PM (3 d, 20 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18866256
Default Alt Text
kolab-mta-join-script.sh (2 KB)
Attached To
Mode
rKMETA kolab
Attached
Detach File
Event Timeline