diff options
author | Rob Crittenden <rcritten@redhat.com> | 2010-09-10 17:51:08 -0400 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2010-09-16 11:54:43 -0400 |
commit | d57dd9534d97055803b7be67b56fc61bbd9a4ab5 (patch) | |
tree | 9f4b2efb41440fe77f0a232f833ba41bf4b2ab58 | |
parent | d43eb785f55104a05af624078a47c397477d49b3 (diff) | |
download | freeipa-d57dd9534d97055803b7be67b56fc61bbd9a4ab5.tar.gz freeipa-d57dd9534d97055803b7be67b56fc61bbd9a4ab5.tar.xz freeipa-d57dd9534d97055803b7be67b56fc61bbd9a4ab5.zip |
Add --no-host-dns argument to ipa-replica-install
The server installer has this option, the replica installer should have
it too.
ticket 146
-rwxr-xr-x | install/tools/ipa-replica-install | 9 | ||||
-rw-r--r-- | install/tools/man/ipa-replica-install.1 | 23 |
2 files changed, 19 insertions, 13 deletions
diff --git a/install/tools/ipa-replica-install b/install/tools/ipa-replica-install index 4bf15067e..9249c9f7c 100755 --- a/install/tools/ipa-replica-install +++ b/install/tools/ipa-replica-install @@ -64,6 +64,9 @@ def parse_options(): help="Add a DNS forwarder") parser.add_option("--no-forwarders", dest="no_forwarders", action="store_true", default=False, help="Do not add any DNS forwarders, use root servers instead") + parser.add_option("--no-host-dns", dest="no_host_dns", action="store_true", + default=False, + help="Do not use DNS for hostname lookup during installation") options, args = parser.parse_args() @@ -108,10 +111,10 @@ def read_info(dir, rconfig): rconfig.host_name = config.get("realm", "destination_host") rconfig.subject_base = config.get("realm", "subject_base") -def get_host_name(): +def get_host_name(no_host_dns): hostname = installutils.get_fqdn() try: - installutils.verify_fqdn(hostname) + installutils.verify_fqdn(hostname, no_host_dns) except RuntimeError, e: logging.error(str(e)) sys.exit(1) @@ -285,7 +288,7 @@ def main(): config = ReplicaConfig() read_info(dir, config) config.dirman_password = dirman_password - host = get_host_name() + host = get_host_name(options.no_host_dns) if config.host_name != host: try: print "This replica was created for '%s' but this machine is named '%s'" % (config.host_name, host) diff --git a/install/tools/man/ipa-replica-install.1 b/install/tools/man/ipa-replica-install.1 index dd9a9ae99..a15093012 100644 --- a/install/tools/man/ipa-replica-install.1 +++ b/install/tools/man/ipa-replica-install.1 @@ -1,21 +1,21 @@ .\" A man page for ipa-replica-install .\" Copyright (C) 2008 Red Hat, Inc. -.\" +.\" .\" This is free software; you can redistribute it and/or modify it under .\" the terms of the GNU Library General Public License as published by .\" the Free Software Foundation; version 2 only -.\" +.\" .\" This program is distributed 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 .\" General Public License for more details. -.\" +.\" .\" You should have received a copy of the GNU Library General Public .\" License along with this program; if not, write to the Free Software .\" Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -.\" +.\" .\" Author: Rob Crittenden <rcritten@redhat.com> -.\" +.\" .TH "ipa-replica-install" "1" "Mar 14 2008" "freeipa" "" .SH "NAME" ipa\-replica\-install \- Create an IPA replica @@ -26,21 +26,21 @@ Configures a new IPA server that is a replica of the server that generated it. O The replica_file is created using the ipa\-replica\-prepare utility. .SH "OPTIONS" -.TP +.TP \fB\-d\fR, \fB\-\-debug Enable debug logging when more verbose output is needed -.TP +.TP \fB\-n\fR, \fB\-\-no\-ntp\fR Do not configure NTP -.TP -\fB\-p\fR, \fB\-\-password\fR=\fIDM_PASSWORD\fR +.TP +\fB\-p\fR, \fB\-\-password\fR=\fIDM_PASSWORD\fR Directory Manager (existing master) password .TP \fB\-\-setup\-dns\fR Generate a DNS zone if it does not exist already and configure the DNS server. This option requires that you either specify at least one DNS forwarder through the \fB\-\-forwarder\fR option or use the \fB\-\-no\-forwarders\fR option. -.TP +.TP \fB\-\-forwarder\fR=\fIIP_ADDRESS\fR Add a DNS forwarder to the DNS configuration. You can use this option multiple times to specify more forwarders, but at least one must be provided, unless @@ -48,6 +48,9 @@ the \fB\-\-no\-forwarders\fR option is specified. .TP \fB\-\-no\-forwarders\fR Do not add any DNS forwarders. Root DNS servers will be used instead. +.TP +\fB\-\-no\-host\-dns\fR +Do not use DNS for hostname lookup during installation .SH "EXIT STATUS" 0 if the command was successful |