spacewalk/admin/Makefile.admin | 1
spacewalk/admin/rhn-config-tnsnames.pl | 106 ---------------------------------
spacewalk/admin/spacewalk-admin.spec | 1
3 files changed, 108 deletions(-)
New commits:
commit a1c217b1521cc5cb43c21929d9c80446c29e9f20
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Tue Jan 18 16:37:30 2011 +0100
The rhn-config-tnsnames.pl is no longer used, removing.
diff --git a/spacewalk/admin/Makefile.admin b/spacewalk/admin/Makefile.admin
index 876c6e7..dc55696 100644
--- a/spacewalk/admin/Makefile.admin
+++ b/spacewalk/admin/Makefile.admin
@@ -31,7 +31,6 @@ GPGKEY_DEST = $(PREFIX)/$(GPGKEYDIR)
PERL_SCRIPTS = rhn-config-satellite.pl \
rhn-config-schema.pl \
- rhn-config-tnsnames.pl \
rhn-deploy-ca-cert.pl \
rhn-install-ssl-cert.pl \
rhn-populate-database.pl \
diff --git a/spacewalk/admin/rhn-config-tnsnames.pl
b/spacewalk/admin/rhn-config-tnsnames.pl
deleted file mode 100755
index 2b2871f..0000000
--- a/spacewalk/admin/rhn-config-tnsnames.pl
+++ /dev/null
@@ -1,106 +0,0 @@
-#!/usr/bin/perl
-#
-# Copyright (c) 2008--2010 Red Hat, Inc.
-#
-# This software is licensed to you under the GNU General Public License,
-# version 2 (GPLv2). There is NO WARRANTY for this software, express or
-# implied, including the implied warranties of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE. You should have received a copy of GPLv2
-# along with this software; if not, see
-#
http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
-#
-# Red Hat trademarks are not licensed under GPLv2. No permission is
-# granted to use or replicate Red Hat trademarks that are incorporated
-# in this software or its documentation.
-#
-#
-# $Id$
-
-use strict;
-use warnings;
-
-use Getopt::Long;
-use English;
-
-$ENV{PATH} = '/bin:/usr/bin';
-
-my $usage = "usage: $0 --target=<target_file> --sid=<sid>
--address=<proto,host,port> "
- . "[ --address=<proto,host,port> ] [ --help ]\n";
-
-my $target = '';
-my $sid = '';
-my @options = ();
-my $help = '';
-
-GetOptions("target=s" => \$target, "sid=s" => \$sid,
"address=s" => \@options, "help" => \$help) or die $usage;
-
-if ($help) {
- die $usage;
-}
-
-unless ($target and $sid and (@options)) {
- die $usage;
-}
-
-my @addresses = parse_addresses(@options);
-my $tnsdata = generate_tnsnames($sid, \@addresses);
-
-if (-e $target) {
- rename($target, $target . ".orig") or die "Could not rename $target to
${target}.orig: $OS_ERROR";
-}
-
-open(TARGET, "> $target") or die "Could not open $target:
$OS_ERROR";
-select(TARGET);
-
-print $tnsdata;
-
-close(TARGET);
-
-exit 0;
-
-sub parse_addresses {
- my @options = @_;
- my @addresses;
-
- foreach my $opt (@options) {
- my @line = split(/,/, $opt);
- push @addresses, { protocol => $line[0],
- host => $line[1],
- port => $line[2],
- };
- }
-
- return @addresses;
-}
-
-sub generate_tnsnames {
- my $sid = shift;
- my $addresses = shift;
-
- my $tnsnames_template =<<EOQ;
-%s =
- (DESCRIPTION =
- (ADDRESS_LIST =
-%s
- )
- (CONNECT_DATA =
- (SID = %s)
- )
- )
-EOQ
-
- my $address_template = (' ' x 6) . '(ADDRESS = (PROTOCOL = %s)(HOST =
%s)(PORT = %s))';
-
- my @address_lines;
-
- foreach my $address (@{$addresses}) {
- push @address_lines,
- sprintf($address_template, $address->{protocol}, $address->{host},
$address->{port});
- }
-
- my $tnsnames = sprintf($tnsnames_template, $sid, join("\n", @address_lines),
$sid);
-
- return $tnsnames;
-}
-
-
diff --git a/spacewalk/admin/spacewalk-admin.spec b/spacewalk/admin/spacewalk-admin.spec
index b90c5e4..8ffdd06 100644
--- a/spacewalk/admin/spacewalk-admin.spec
+++ b/spacewalk/admin/spacewalk-admin.spec
@@ -55,7 +55,6 @@ rm -rf $RPM_BUILD_ROOT
%{_bindir}/validate-sat-cert
%{_bindir}/rhn-config-satellite.pl
%{_bindir}/rhn-config-schema.pl
-%{_bindir}/rhn-config-tnsnames.pl
%{_bindir}/rhn-populate-database.pl
%{_bindir}/rhn-generate-pem.pl
%{_bindir}/rhn-sudo-load-ssl-cert