client/solaris rel-eng/packages
by Michael Mraka
client/solaris/smartpm/smartpm.spec | 7 ++++++-
rel-eng/packages/smartpm | 2 +-
2 files changed, 7 insertions(+), 2 deletions(-)
New commits:
commit ca1247eb176bece0904fea22f19691a1151854c2
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Jul 15 14:11:50 2011 +0200
Automatic commit of package [smartpm] minor release [0.2-4].
diff --git a/client/solaris/smartpm/smartpm.spec b/client/solaris/smartpm/smartpm.spec
index a1546bd..739a927 100644
--- a/client/solaris/smartpm/smartpm.spec
+++ b/client/solaris/smartpm/smartpm.spec
@@ -11,7 +11,7 @@ Name: smartpm
Source0: smartpm-%{version}.tar.gz
Epoch: 1
Version: 0.2
-Release: 3
+Release: 4
License: GPLv2
Group: Applications/System
URL: http://www.smartpm.org/
@@ -57,6 +57,11 @@ env %{__python} setup.py build
%{python_sitearch}/rhn/actions/solarispkgs.py*
%changelog
+* Fri Jul 15 2011 Michael Mraka <michael.mraka(a)redhat.com> 0.2-4
+- 559092 - fixed patchset installation on x86
+- 559092 - made patch cluster dir readable for nobody
+- 559092 - new solaris patches contain installcluster
+
* Mon May 24 2010 Miroslav Suchý <msuchy(a)redhat.com> 0.2-3
- return smartpm back to 0.2 version and bump up epoch
- 555659 - do not freak out when SUNW_PATCHID do not have SUN format
diff --git a/rel-eng/packages/smartpm b/rel-eng/packages/smartpm
index bcdb31b..8bc7d1a 100644
--- a/rel-eng/packages/smartpm
+++ b/rel-eng/packages/smartpm
@@ -1 +1 @@
-0.2-3 client/solaris/smartpm/
+0.2-4 client/solaris/smartpm/
12 years, 9 months
2 commits - client/solaris
by Michael Mraka
client/solaris/smartpm/smart/backends/solaris/pm.py | 2 ++
client/solaris/smartpm/smartpm.spec | 3 ---
2 files changed, 2 insertions(+), 3 deletions(-)
New commits:
commit 501775953439fec0caf3570e24b83ddc045df511
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Jul 15 14:05:51 2011 +0200
559092 - fixed patchset installation on x86
diff --git a/client/solaris/smartpm/smart/backends/solaris/pm.py b/client/solaris/smartpm/smart/backends/solaris/pm.py
index 08b7905..dd2f08f 100644
--- a/client/solaris/smartpm/smart/backends/solaris/pm.py
+++ b/client/solaris/smartpm/smart/backends/solaris/pm.py
@@ -96,6 +96,8 @@ def solinstall(adminfile, path, pkg, prog=None):
if pkg.name.startswith("patch-cluster-solaris-"):
if os.path.exists(os.path.join(pkgdir, 'install_cluster')):
cmd = "%s/install_cluster -q" % pkgdir
+ elif os.path.exists(os.path.join(pkgdir, 'installpatchset')):
+ cmd = "%s/installpatchset --s10patchset" % pkgdir
elif os.path.exists(os.path.join(pkgdir, 'installcluster')):
cmd = "%s/installcluster --s10cluster" % pkgdir
else:
commit d430c55c7ffc1e2a59848ffe56f1d14b3ca20319
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Jul 15 14:04:43 2011 +0200
removed already commented out BuildRequires
diff --git a/client/solaris/smartpm/smartpm.spec b/client/solaris/smartpm/smartpm.spec
index 9e6f51b..a1546bd 100644
--- a/client/solaris/smartpm/smartpm.spec
+++ b/client/solaris/smartpm/smartpm.spec
@@ -18,9 +18,6 @@ URL: http://www.smartpm.org/
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
-##BuildRequires: popt, rpm-devel >= 4.2.1, python-devel
-##BuildRequires: autoconf, automake
-
Requires: python = %{python_version}
%description
12 years, 9 months
Changes to 'refs/tags/spacewalk-java-1.5.56-1'
by Miroslav Suchý
Tag 'spacewalk-java-1.5.56-1' created by Miroslav Suchý <msuchy(a)redhat.com> at 2011-07-14 07:48 +0000
Tagging package [spacewalk-java] version [1.5.56-1] in directory [java/].
Changes since spacewalk-backend-1.5.40-1:
Miroslav Suchý (3):
do not use deprecated module "string"
changing query to cursor mode - avoid loading all records (4M+ records) into memory
Automatic commit of package [spacewalk-java] release [1.5.56-1].
Tomas Lestach (1):
720282 - fix some issues when spacewalk-koan needs to be installed for systems to kickstart
---
backend/common/fileutils.py | 5 -
backend/common/rhnLog.py | 5 -
backend/common/rhnMail.py | 3 -
backend/common/rhnRepository.py | 13 ++--
backend/common/rhnTB.py | 7 +-
backend/po/pygettext.py | 11 +--
backend/satellite_tools/exporter/exportLib.py | 25 ++++----
backend/satellite_tools/geniso.py | 5 -
backend/satellite_tools/rhn-satellite-activate | 3 -
backend/satellite_tools/rhn-ssl-dbstore | 3 -
backend/satellite_tools/rhn_satellite_activate.py | 15 ++---
backend/server/rhnKickstart.py | 4 -
backend/server/rhnUser.py | 13 ++--
backend/upload_server/handlers/package_push/package_push.py | 5 -
java/code/src/com/redhat/rhn/manager/kickstart/KickstartScheduleCommand.java | 30 +++-------
java/code/src/com/redhat/rhn/taskomatic/task/repomd/PackageCapabilityIterator.java | 1
java/spacewalk-java.spec | 8 ++
rel-eng/packages/spacewalk-java | 2
18 files changed, 69 insertions(+), 89 deletions(-)
---
12 years, 9 months
3 commits - backend/common backend/po backend/satellite_tools backend/server backend/upload_server java/code java/spacewalk-java.spec rel-eng/packages
by Miroslav Suchý
backend/common/fileutils.py | 5 --
backend/common/rhnLog.py | 5 --
backend/common/rhnMail.py | 3 -
backend/common/rhnRepository.py | 13 ++---
backend/common/rhnTB.py | 7 +-
backend/po/pygettext.py | 11 ++--
backend/satellite_tools/exporter/exportLib.py | 25 ++++------
backend/satellite_tools/geniso.py | 5 --
backend/satellite_tools/rhn-satellite-activate | 3 -
backend/satellite_tools/rhn-ssl-dbstore | 3 -
backend/satellite_tools/rhn_satellite_activate.py | 15 ++----
backend/server/rhnKickstart.py | 4 -
backend/server/rhnUser.py | 13 ++---
backend/upload_server/handlers/package_push/package_push.py | 5 --
java/code/src/com/redhat/rhn/taskomatic/task/repomd/PackageCapabilityIterator.java | 1
java/spacewalk-java.spec | 8 ++-
rel-eng/packages/spacewalk-java | 2
17 files changed, 60 insertions(+), 68 deletions(-)
New commits:
commit 3edc1fcf34146cc8ed989c70ac48a4efac3ddb09
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Thu Jul 14 09:48:28 2011 +0200
Automatic commit of package [spacewalk-java] release [1.5.56-1].
diff --git a/java/spacewalk-java.spec b/java/spacewalk-java.spec
index 3e11996..846dd70 100644
--- a/java/spacewalk-java.spec
+++ b/java/spacewalk-java.spec
@@ -17,7 +17,7 @@ Name: spacewalk-java
Summary: Spacewalk Java site packages
Group: Applications/Internet
License: GPLv2
-Version: 1.5.55
+Version: 1.5.56
Release: 1%{?dist}
URL: https://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
@@ -546,6 +546,12 @@ fi
%{jardir}/postgresql-jdbc.jar
%changelog
+* Thu Jul 14 2011 Miroslav Suchý 1.5.56-1
+- changing query to cursor mode - avoid loading all records (4M+ records) into
+ memory (msuchy(a)redhat.com)
+- 720282 - fix some issues when spacewalk-koan needs to be installed for
+ systems to kickstart (tlestach(a)redhat.com)
+
* Wed Jul 13 2011 Jan Pazdziora 1.5.55-1
- 720533 - replacing rhnServerNeededView with custom subselect which is
generally equivalent, in the erratamailer_get_relevant_servers context.
diff --git a/rel-eng/packages/spacewalk-java b/rel-eng/packages/spacewalk-java
index 57ed5b9..e5dbd0d 100644
--- a/rel-eng/packages/spacewalk-java
+++ b/rel-eng/packages/spacewalk-java
@@ -1 +1 @@
-1.5.55-1 java/
+1.5.56-1 java/
commit b803f6ef78362eb34d2cfc07ca0c400e40b89dd9
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Thu Jul 14 02:19:41 2011 +0200
changing query to cursor mode - avoid loading all records (4M+ records) into memory
diff --git a/java/code/src/com/redhat/rhn/taskomatic/task/repomd/PackageCapabilityIterator.java b/java/code/src/com/redhat/rhn/taskomatic/task/repomd/PackageCapabilityIterator.java
index d436230..58592bd 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/task/repomd/PackageCapabilityIterator.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/task/repomd/PackageCapabilityIterator.java
@@ -75,6 +75,7 @@ public class PackageCapabilityIterator {
PreparedStatement ps = HibernateFactory.getSession().connection()
.prepareStatement(query);
ps.setLong(1, ch.getId());
+ ps.setFetchSize(200);
rs = ps.executeQuery();
rsmd = rs.getMetaData();
}
commit a8ef8f68a4fff564acce02e7918f526396eae005
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Thu Jul 14 09:46:45 2011 +0200
do not use deprecated module "string"
diff --git a/backend/common/fileutils.py b/backend/common/fileutils.py
index b476533..5b8008f 100644
--- a/backend/common/fileutils.py
+++ b/backend/common/fileutils.py
@@ -19,7 +19,6 @@ import pwd
import grp
import types
import shutil
-import string
import subprocess
import select
import stat
@@ -55,10 +54,10 @@ def cleanupNormPath(path, dotYN=0):
os.path.expanduser(
os.path.expandvars(path)))
if dotYN and not (path and path[0] == '/'):
- dirs = string.split(path, '/')
+ dirs = path.split('/')
if dirs[:1] not in (['.'], ['..']):
dirs = ['.'] + dirs
- path = string.join(dirs, '/')
+ path = '/'.join(dirs)
return path
diff --git a/backend/common/rhnLog.py b/backend/common/rhnLog.py
index 462f5e0..0f990ec 100644
--- a/backend/common/rhnLog.py
+++ b/backend/common/rhnLog.py
@@ -32,7 +32,6 @@
# system module imports
import os
import sys
-import string
import traceback
import time
import fcntl
@@ -193,13 +192,13 @@ class rhnLog:
module = ''
try: # So one can debug from the commandline.
module = tbStack[callid][0]
- arr = string.split(module, '/')
+ arr = module.split('/')
if len(arr) > 1:
lastDir = arr[-2] + "/"
else:
lastDir = ""
filename = arr[-1]
- filename = filename[:string.rindex(filename, '.')]
+ filename = filename[:filename.rindex('.')]
module = lastDir + filename
del lastDir
except:
diff --git a/backend/common/rhnMail.py b/backend/common/rhnMail.py
index 93964bb..97bc229 100644
--- a/backend/common/rhnMail.py
+++ b/backend/common/rhnMail.py
@@ -17,7 +17,6 @@
import os
import sys
-import string
import smtplib
from rhnConfig import CFG
@@ -39,7 +38,7 @@ def __check_headers(h):
h["Content-Type"] = "text/plain; charset=utf-8"
if type(to) in [type([]), type(())]:
toaddrs = to
- to = string.join(to, ', ')
+ to = ', '.join(to)
else:
toaddrs = to.split(',')
h["To"] = to
diff --git a/backend/common/rhnRepository.py b/backend/common/rhnRepository.py
index 052a4bd..e8bcf84 100644
--- a/backend/common/rhnRepository.py
+++ b/backend/common/rhnRepository.py
@@ -17,7 +17,6 @@
import os
import stat
import types
-import string
import cStringIO
from rhn import rpclib
@@ -109,11 +108,11 @@ class Repository(RPC_Base):
""" Get srpm packrge. """
log_debug(3, pkgFilename)
# Sanity check:
- l = string.split(pkgFilename, '.')
+ l = pkgFilename.split('.')
#6/23/05 wregglej 154248, Don't mangle the filename if it's a nosrc package.
if l[-2] != "nosrc":
l[-2] = 'src'
- pkgFilename = string.join(l, '.')
+ pkgFilename = '.'.join(l)
filePath = self.getSourcePackagePath(pkgFilename)
return self._getFile(filePath)
@@ -123,13 +122,13 @@ class Repository(RPC_Base):
change the function name, or version the protocol
"""
log_debug(3, pkgFilename)
- pkg = string.split(pkgFilename, '.')
+ pkg = pkgFilename.split('.')
# Basic sanity checks:
if pkg[-1] not in ["hdr", 'rpm']:
raise rhnFault(21, "'%s' not a valid RPM header name"
% pkgFilename)
- pkgFilename = string.join(pkg[:-1], ".") + '.rpm'
+ pkgFilename = ".".join(pkg[:-1]) + '.rpm'
filePath = self.getPackagePath(pkgFilename)
data = self._getHeaderFromFile(filePath)
# XXX: Interesting. Found that if returned just data, this
@@ -187,10 +186,10 @@ class Repository(RPC_Base):
del h # XXX: not neccessary?
pkgFilename = os.path.basename(filePath)
- pkg = string.split(pkgFilename, '.')
+ pkg = pkgFilename.split('.')
# Replace .rpm with .hdr
pkg[-1] = "hdr"
- pkgFilename = string.join(pkg, ".")
+ pkgFilename = ".".join(pkg)
extra_headers = {
'X-RHN-Package-Header' : pkgFilename,
}
diff --git a/backend/common/rhnTB.py b/backend/common/rhnTB.py
index fccc86d..b967815 100644
--- a/backend/common/rhnTB.py
+++ b/backend/common/rhnTB.py
@@ -18,7 +18,6 @@ import re
import os
import sys
import time
-import string
import traceback
from StringIO import StringIO
from rhn.connections import idn_pune_to_unicode
@@ -164,8 +163,8 @@ def Traceback(method = None, req = None, mail = 1, ostream = sys.stderr,
to = CFG.TRACEBACK_MAIL
fr = to
if isinstance(to, type([])):
- fr = string.strip(to[0])
- to = string.join(map(string.strip, to), ', ')
+ fr = to[0].strip()
+ to = ', '.join(map(lambda x: x.strip(), to))
headers = {
"Subject" : "RHN TRACEBACK from %s" % unicode_hostname,
"From" : "%s <%s>" % (hostname, fr),
@@ -231,7 +230,7 @@ def censor_string(strval):
censorlist = get_seclist()
for c in censorlist:
#Censor it with a fixed length string. This way the length of the hidden string isn't revealed.
- strval = string.replace(strval, c, "<CENSORED!>")
+ strval = strval.replace(c, "<CENSORED!>")
return strval
def add_to_seclist(obj):
diff --git a/backend/po/pygettext.py b/backend/po/pygettext.py
index 9e82482..dbad466 100755
--- a/backend/po/pygettext.py
+++ b/backend/po/pygettext.py
@@ -131,13 +131,12 @@ import os
import sys
import time
import getopt
-import string
import tokenize
__version__ = '1.1'
default_keywords = ['_']
-DEFAULTKEYWORDS = string.join(default_keywords, ', ')
+DEFAULTKEYWORDS = ', '.join(default_keywords)
EMPTYSTRING = ''
@@ -194,7 +193,7 @@ def escape(s):
s = list(s)
for i in range(len(s)):
s[i] = escapes[ord(s[i])]
- return string.join(s, '')
+ return ''.join(s)
def safe_eval(s):
@@ -205,7 +204,7 @@ def safe_eval(s):
def normalize(s):
# This converts the various Python string types into a format that is
# appropriate for .po files, namely much closer to C style.
- lines = string.split(s, '\n')
+ lines = s.split('\n')
if len(lines) == 1:
s = '"' + escape(s) + '"'
else:
@@ -215,7 +214,7 @@ def normalize(s):
for i in range(len(lines)):
lines[i] = escape(lines[i])
lineterm = '\\n"\n"'
- s = '""\n"' + string.join(lines, lineterm) + '"'
+ s = '""\n"' + lineterm.join(lines) + '"'
return s
@@ -250,7 +249,7 @@ class TokenEater:
# of messages seen. Reset state for the next batch. If there
# were no strings inside _(), then just ignore this entry.
if self.__data:
- msg = string.join(self.__data,"")
+ msg = ''.join(self.__data)
if not msg in self.__options.toexclude:
entry = (self.__curfile, self.__lineno)
linenos = self.__messages.get(msg)
diff --git a/backend/satellite_tools/exporter/exportLib.py b/backend/satellite_tools/exporter/exportLib.py
index 597c4c7..c45416e 100644
--- a/backend/satellite_tools/exporter/exportLib.py
+++ b/backend/satellite_tools/exporter/exportLib.py
@@ -14,7 +14,6 @@
#
import time
-import string
from types import StringType
from spacewalk.common import rhnLib
@@ -223,9 +222,9 @@ class _ChannelDumper(BaseRowDumper):
'label' : self._row['label'],
'org_id' : self._row['org_id'] or "",
'channel-arch' : self._row['channel_arch'],
- 'packages' : string.join(packages),
- 'channel-errata' : string.join(errata),
- 'kickstartable-trees' : string.join(ks_trees),
+ 'packages' : ' '.join(packages),
+ 'channel-errata' : ' '.join(errata),
+ 'kickstartable-trees' : ' '.join(ks_trees),
}
_query_channel_families = rhnSQL.Statement("""
@@ -638,15 +637,15 @@ class _ChannelFamilyDumper(BaseRowDumper):
log_debug(3, cf_virt_data, channel_family_id)
vsl_label = map(lambda x: x['label'], cf_virt_data)
- cf_vsl_label = string.join(vsl_label)
+ cf_vsl_label = ' '.join(vsl_label)
vsl_name = map(lambda x: x['name'], cf_virt_data)
- cf_vsl_name = string.join(vsl_name, ',')
+ cf_vsl_name = ','.join(vsl_name)
attributes = {
'id' : "rhn-channel-family-%s" % channel_family_id,
'label' : self._row['label'],
- 'channel-labels': string.join(channels),
+ 'channel-labels': ' '.join(channels),
}
if not self._virt_filter and cf_virt_data != []:
attributes['virt-sub-level-label'] = cf_vsl_label
@@ -678,7 +677,7 @@ class _PackageDumper(BaseRowDumper):
'last-modified' : _dbtime2timestamp(self._row['last_modified']),
}
for attr in attrs:
- dict[string.replace(attr, '_', '-')] = self._row[attr]
+ dict[attr.replace('_', '-')] = self._row[attr]
if self._row['checksum_type'] == 'md5':
# compatibility with older satellite
dict['md5sum'] = self._row['checksum']
@@ -807,7 +806,7 @@ class SourcePackagesDumper(BaseQueryDumper):
"cookie", "package_size", "checksum_type", "checksum"
]
for attr in attrs:
- attributes[string.replace(attr, '_', '-')] = data[attr]
+ attributes[attr.replace('_', '-')] = data[attr]
attributes['id'] = "rhn-source-package-%s" % data['id']
attributes['build-time'] = _dbtime2timestamp(data['build_time'])
attributes['last-modified'] = _dbtime2timestamp(data['last_modified'])
@@ -917,9 +916,9 @@ class _ErratumDumper(BaseRowDumper):
'id' : 'rhn-erratum-%s' % self._row['id'],
'org_id' : self._row['org_id'] or "",
'advisory' : self._row['advisory'],
- 'channels' : string.join(channels),
- 'packages' : string.join(packages),
- 'cve-names' : string.join(cves),
+ 'channels' : ' '.join(channels),
+ 'packages' : ' '.join(packages),
+ 'cve-names' : ' '.join(cves),
}
type_id_column = ""
@@ -1034,7 +1033,7 @@ class _ErratumFileEntryDumper(BaseChecksumRowDumper):
and efc.channel_id = c.id
""")
h.execute(errata_file_id=self._row['errata_file_id'])
- channels = string.join(
+ channels = ' '.join(
map(lambda x: x['label'], h.fetchall_dict() or []))
if channels:
attributes['channels'] = channels
diff --git a/backend/satellite_tools/geniso.py b/backend/satellite_tools/geniso.py
index 9910041..3ef3a5f 100644
--- a/backend/satellite_tools/geniso.py
+++ b/backend/satellite_tools/geniso.py
@@ -17,7 +17,6 @@
import os
import sys
import time
-import string
from stat import ST_SIZE
from optparse import Option, OptionParser
@@ -147,7 +146,7 @@ def main(arglist):
grafts.append("%s/=%s" % (relpath, f))
# Generate the command line
- cmd = mkisofsTemplate % (string.join(opts), filename, i+1, cdcount,
+ cmd = mkisofsTemplate % (' '.join(opts), filename, i+1, cdcount,
empty_file_path)
# Write the path specs in pathfiles
@@ -196,7 +195,7 @@ def sizeStrToInt(s):
if s[-1] in ('k', 'K', 'm', 'M'):
# Specified a multiplier
- if string.lower(s[-1]) == 'k':
+ if s[-1].lower() == 'k':
mult = 1024
else:
mult = 1024 * 1024
diff --git a/backend/satellite_tools/rhn-satellite-activate b/backend/satellite_tools/rhn-satellite-activate
index c650db7..c56f9b6 100755
--- a/backend/satellite_tools/rhn-satellite-activate
+++ b/backend/satellite_tools/rhn-satellite-activate
@@ -18,13 +18,12 @@
import sys
try:
import os
- import string
except KeyboardInterrupt:
sys.stderr.write("\nUser interrupted process.\n")
sys.exit(0)
-mod_name = string.replace(os.path.basename(sys.argv[0]), '-', '_')
+mod_name = os.path.basename(sys.argv[0]).replace('-', '_')
try:
mod = __import__("spacewalk.satellite_tools", globals(), locals(), [mod_name])
except KeyboardInterrupt:
diff --git a/backend/satellite_tools/rhn-ssl-dbstore b/backend/satellite_tools/rhn-ssl-dbstore
index 362b7fd..bfc75b0 100755
--- a/backend/satellite_tools/rhn-ssl-dbstore
+++ b/backend/satellite_tools/rhn-ssl-dbstore
@@ -19,13 +19,12 @@
import sys
try:
import os
- import string
except KeyboardInterrupt:
sys.stderr.write("\nUser interrupted process.\n")
sys.exit(0)
-mod_name = string.replace(os.path.basename(sys.argv[0]), '-', '_')
+mod_name = os.path.basename(sys.argv[0]).replace('-', '_')
try:
mod = __import__("spacewalk.satellite_tools", globals(), locals(), [mod_name])
except KeyboardInterrupt:
diff --git a/backend/satellite_tools/rhn_satellite_activate.py b/backend/satellite_tools/rhn_satellite_activate.py
index 7d2c6c9..eee7910 100644
--- a/backend/satellite_tools/rhn_satellite_activate.py
+++ b/backend/satellite_tools/rhn_satellite_activate.py
@@ -18,7 +18,6 @@ import os
import sys
import time
import gzip
-import string
from optparse import Option, OptionParser
from rhn import rpclib
from rhn.connections import idn_ascii_to_pune
@@ -114,7 +113,7 @@ def validateSatCert(certFilename, verbosity=0):
# doesn't like).
fd, certTmpFile = tempfile.mkstemp(prefix = DEFAULT_RHN_CERT_LOCATION + '-')
fo = os.fdopen(fd, 'wb')
- fo.write(string.strip(openGzippedFile(certFilename).read()))
+ fo.write(openGzippedFile(certFilename).read().strip())
fo.flush()
fo.close()
@@ -122,7 +121,7 @@ def validateSatCert(certFilename, verbosity=0):
DEFAULT_WEBAPP_GPG_KEY_RING, certTmpFile]
if verbosity:
- print "Checking cert XML sanity and GPG signature:", repr(string.join(args))
+ print "Checking cert XML sanity and GPG signature:", repr(' '.join(args))
ret, out, err = fileutils.rhn_popen(args)
err = err.read()
@@ -131,7 +130,7 @@ def validateSatCert(certFilename, verbosity=0):
# nuke temp cert
os.unlink(certTmpFile)
- if string.find(err, 'verify err') != -1 or ret:
+ if err.find('verify err') != -1 or ret:
msg = "%s Entitlement Certificate failed to validate.\n" % PRODUCT_NAME
msg = msg + "MORE INFORMATION:\n"
msg = msg + " Return value: %s\n" % ret +\
@@ -169,7 +168,7 @@ def prepRhnCert(options):
'could not be opened and read:\n%s') % (options.rhn_cert, str(e))
sys.stderr.write(msg+'\n')
raise
- cert = string.strip(cert)
+ cert = cert.strip()
try:
writeRhnCert(options, cert)
except (IOError, OSError), e:
@@ -412,7 +411,7 @@ def populateChannelFamilies(options):
# args.extend(['--db', options.db])
if options.verbose:
- print "Executing: %s\n" % repr(string.join(args))
+ print "Executing: %s\n" % repr(' '.join(args))
ret, out_stream, err_stream = fileutils.rhn_popen(args)
if ret:
msg_ = "Population of the Channel Family permissions failed."
@@ -436,7 +435,7 @@ def expiredYN(certPath):
sys.stderr.write("ERROR: unable to open the cert: %s\n" % certPath)
sys.exit(1)
- cert = string.strip(fo.read())
+ cert = fo.read().strip()
fo.close()
## parse it and snag "expires"
@@ -502,7 +501,7 @@ def processCommandline():
if not CFG.RHN_PARENT:
sys.stderr.write("ERROR: rhn_parent is not set in /etc/rhn/rhn.conf\n")
sys.exit(1)
- options.server = idn_ascii_to_pune(string.split(rhnLib.parseUrl(CFG.RHN_PARENT)[1], ':')[0])
+ options.server = idn_ascii_to_pune(rhnLib.parseUrl(CFG.RHN_PARENT)[1].split(':')[0])
print 'RHN_PARENT: %s' % options.server
options.http_proxy = idn_ascii_to_pune(CFG.HTTP_PROXY)
diff --git a/backend/server/rhnKickstart.py b/backend/server/rhnKickstart.py
index 2b9b23e..510fd57 100644
--- a/backend/server/rhnKickstart.py
+++ b/backend/server/rhnKickstart.py
@@ -13,8 +13,6 @@
# in this software or its documentation.
#
-import string
-
# common module
from spacewalk.common.rhnLog import log_debug
from spacewalk.common.rhnException import rhnFault
@@ -139,7 +137,7 @@ class Kickstart:
for channel_pkg in channel_pkgs:
# If we find the pkg, set found and break the loop.
- if string.find(string.lower(channel_pkg[0]), string.lower(pkg)) > 0:
+ if channel_pkg[0].lower().find(pkg.lower()) > 0:
found = 1
break
diff --git a/backend/server/rhnUser.py b/backend/server/rhnUser.py
index 1399a2e..3b48a89 100644
--- a/backend/server/rhnUser.py
+++ b/backend/server/rhnUser.py
@@ -18,7 +18,6 @@
import re
import crypt
-import string
# Global Modules
from rhn.UserDictCase import UserDictCase
@@ -131,7 +130,7 @@ class User:
def set_contact_perm(self, name, value):
""" handling of contact permissions """
if not name: return -1
- n = string.lower(name)
+ n = name.lower()
v = 'N'
if value:
v = 'Y'
@@ -153,9 +152,9 @@ class User:
}
if not name:
return -1
- name = string.lower(name)
+ name = name.lower()
if type(value) == type(""):
- value = string.strip(value)
+ value = value.strip()
# We have to watch over carefully for different field names
# being sent from rhn_register
changed = 0
@@ -600,7 +599,7 @@ def __new_user_db(username, password, email, org_id, org_password):
if not data: # wrong organization
raise rhnFault(2, _("Invalid Organization Credentials"))
# The org password is not encrypted, easy comparison
- if string.lower(org_password) != string.lower(data["password"]):
+ if org_password.lower() != data["password"].lower():
# Invalid org password
raise rhnFault(2, _("Invalid Organization Credentials"))
if is_real: # this is a real entry, don't clobber the org_id
@@ -661,7 +660,7 @@ def check_user_password(username, password):
def check_email(email):
""" Do some minimal checks on the e-mail address """
if email is not None:
- email = string.strip(email)
+ email = email.strip()
if not email:
# Still supported
@@ -779,6 +778,6 @@ def validate_new_username(username):
log_debug(4, "Disallowed suffixes", disallowed_suffixes)
for suffix in disallowed_suffixes:
- if string.upper(username[-len(suffix):]) == string.upper(suffix):
+ if username[-len(suffix):].upper() == suffix.upper():
raise rhnFault(106, _("Cannot register usernames ending with %s") %
suffix)
diff --git a/backend/upload_server/handlers/package_push/package_push.py b/backend/upload_server/handlers/package_push/package_push.py
index 97bf404..8fb49fb 100644
--- a/backend/upload_server/handlers/package_push/package_push.py
+++ b/backend/upload_server/handlers/package_push/package_push.py
@@ -20,7 +20,6 @@
import os
import base64
-import string
from rhn import rpclib
from spacewalk.common import apache, rhnFlags
@@ -163,7 +162,7 @@ class PackagePush(basePackageUpload.BasePackageUpload):
return apache.OK
def get_auth_token(self, value):
- s = string.join(map(string.strip, string.split(value, ',')), '')
- arr = map(base64.decodestring, string.split(s, ':'))
+ s = ''.join(map(lambda x: x.strip(), value.split('')))
+ arr = map(base64.decodestring, s.split(':'))
return arr
12 years, 9 months
java/code
by Tomas Lestach
java/code/src/com/redhat/rhn/manager/kickstart/KickstartScheduleCommand.java | 30 +++-------
1 file changed, 9 insertions(+), 21 deletions(-)
New commits:
commit a19054e2b131eefa62d5c29df58132e0727fc501
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Mon Jul 11 19:02:38 2011 +0200
720282 - fix some issues when spacewalk-koan needs to be installed for systems to kickstart
diff --git a/java/code/src/com/redhat/rhn/manager/kickstart/KickstartScheduleCommand.java b/java/code/src/com/redhat/rhn/manager/kickstart/KickstartScheduleCommand.java
index 4b1a255..547ae6c 100644
--- a/java/code/src/com/redhat/rhn/manager/kickstart/KickstartScheduleCommand.java
+++ b/java/code/src/com/redhat/rhn/manager/kickstart/KickstartScheduleCommand.java
@@ -65,6 +65,7 @@ import org.apache.commons.lang.StringUtils;
import org.apache.log4j.Logger;
import org.cobbler.SystemRecord;
+import java.util.ArrayList;
import java.util.Collections;
import java.util.Date;
import java.util.HashMap;
@@ -837,22 +838,8 @@ public class KickstartScheduleCommand extends BaseSystemOperation {
}
}
-
- KickstartData data = getKsdata();
- if (!data.isRawData()) {
- // Check that we have a tools channel. The host server needs to contain the
- // tools channel since it is the one performing the actions.
-
- log.debug("** Checking for a Spacewalk tools channel");
- Channel toolsChannel = getToolsChannel(this.ksdata, this.user, hostServer);
- if (toolsChannel == null) {
- Object[] args = new Object[2];
- args[0] = this.getKsdata().getChannel().getId();
- args[1] = this.getKsdata().getChannel().getName();
- return new ValidatorError("kickstart.session.notoolschannel",
- args);
- }
- }
+ // we already shall be subscribed to the tools channel
+ // (since validateKickstartPackage), so no other actions needed
return null;
}
@@ -1103,18 +1090,19 @@ public class KickstartScheduleCommand extends BaseSystemOperation {
}
Server hostServer = getHostServer();
- Set channelIds = SystemManager.subscribableChannelIds(hostServer.getId(),
- this.user.getId(), hostServer.getBaseChannel().getId());
-
- // Add list of channels
+ List channelIds = new ArrayList();
Set serverChannelIds = new HashSet();
Iterator i = hostServer.getChannels().iterator();
while (i.hasNext()) {
Channel c = (Channel) i.next();
serverChannelIds.add(c.getId());
}
-
+ // first add channels, the system is currently subscribed to
channelIds.addAll(serverChannelIds);
+ // then add all the other subscribable channels
+ channelIds.addAll(SystemManager.subscribableChannelIds(hostServer.getId(),
+ this.user.getId(), hostServer.getBaseChannel().getId()));
+
i = channelIds.iterator();
while (i.hasNext()) {
Object id = i.next();
12 years, 9 months
Changes to 'refs/tags/spacewalk-backend-1.5.40-1'
by Jan Pazdziora
Tag 'spacewalk-backend-1.5.40-1' created by Jan Pazdziora <jpazdziora(a)redhat.com> at 2011-07-13 11:48 +0000
Tagging package [spacewalk-backend] version [1.5.40-1] in directory [backend/].
Changes since spacewalk-utils-1.5.4-1:
Jan Pazdziora (1):
Automatic commit of package [spacewalk-backend] release [1.5.40-1].
Marcelo Moreira de Mello (1):
633400 - rhncfg-client lists lower-ranked config channel for file
---
backend/server/handlers/config/rhn_config_management.py | 7 ++++++-
backend/spacewalk-backend.spec | 6 +++++-
rel-eng/packages/spacewalk-backend | 2 +-
3 files changed, 12 insertions(+), 3 deletions(-)
---
12 years, 9 months
backend/spacewalk-backend.spec rel-eng/packages
by Jan Pazdziora
backend/spacewalk-backend.spec | 6 +++++-
rel-eng/packages/spacewalk-backend | 2 +-
2 files changed, 6 insertions(+), 2 deletions(-)
New commits:
commit 18e7ae395d31ac13b05c528e1c7018229fb643a1
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Jul 13 13:48:03 2011 +0200
Automatic commit of package [spacewalk-backend] release [1.5.40-1].
diff --git a/backend/spacewalk-backend.spec b/backend/spacewalk-backend.spec
index 76aa429..1d0e764 100644
--- a/backend/spacewalk-backend.spec
+++ b/backend/spacewalk-backend.spec
@@ -11,7 +11,7 @@ Name: spacewalk-backend
Summary: Common programs needed to be installed on the Spacewalk servers/proxies
Group: Applications/Internet
License: GPLv2 and Python
-Version: 1.5.39
+Version: 1.5.40
Release: 1%{?dist}
URL: https://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
@@ -681,6 +681,10 @@ rm -f %{rhnconf}/rhnSecret.py*
# $Id$
%changelog
+* Wed Jul 13 2011 Jan Pazdziora 1.5.40-1
+- 633400 - rhncfg-client lists lower-ranked config channel for file
+ (mmello(a)redhat.com)
+
* Wed Jul 13 2011 Miroslav Suchý 1.5.39-1
- 695282 - censor password from registration.reserve_user if it appears in TB
diff --git a/rel-eng/packages/spacewalk-backend b/rel-eng/packages/spacewalk-backend
index 1b31fca..40f94bb 100644
--- a/rel-eng/packages/spacewalk-backend
+++ b/rel-eng/packages/spacewalk-backend
@@ -1 +1 @@
-1.5.39-1 backend/
+1.5.40-1 backend/
12 years, 9 months
backend/server
by Jan Pazdziora
backend/server/handlers/config/rhn_config_management.py | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
New commits:
commit 46830082e095a9273ef2e5fe6fcd3a91eb14a952
Author: Marcelo Moreira de Mello <mmello(a)redhat.com>
Date: Tue Jul 12 21:09:56 2011 -0300
633400 - rhncfg-client lists lower-ranked config channel for file
diff --git a/backend/server/handlers/config/rhn_config_management.py b/backend/server/handlers/config/rhn_config_management.py
index f35b3e4..273cefd 100644
--- a/backend/server/handlers/config/rhn_config_management.py
+++ b/backend/server/handlers/config/rhn_config_management.py
@@ -144,7 +144,12 @@ class ConfigManagement(configFilesHandler.ConfigFilesHandler):
break
path = row['path']
- result_hash[path] = (config_channel, path, row['config_file_type_id'])
+
+ if not path in result_hash:
+ result_hash[path] = (config_channel, path, row['config_file_type_id'])
+
+ if config_channel == str(self.server.getid()):
+ result_hash[path] = (config_channel, path, row['config_file_type_id'])
result = result_hash.values()
# Sort by path first since that's what the web site does
12 years, 9 months
Changes to 'refs/tags/spacewalk-utils-1.5.4-1'
by Jan Pazdziora
Tag 'spacewalk-utils-1.5.4-1' created by Jan Pazdziora <jpazdziora(a)redhat.com> at 2011-07-13 07:47 +0000
Tagging package [spacewalk-utils] version [1.5.4-1] in directory [utils/].
Changes since spacewalk-java-1.5.55-1:
Jan Pazdziora (2):
We get either undefined value or BLOB for the blob columns type.
Automatic commit of package [spacewalk-utils] release [1.5.4-1].
---
rel-eng/packages/spacewalk-utils | 2 +-
utils/spacewalk-dump-schema | 2 +-
utils/spacewalk-utils.spec | 5 ++++-
3 files changed, 6 insertions(+), 3 deletions(-)
---
12 years, 9 months
2 commits - rel-eng/packages utils/spacewalk-dump-schema utils/spacewalk-utils.spec
by Jan Pazdziora
rel-eng/packages/spacewalk-utils | 2 +-
utils/spacewalk-dump-schema | 2 +-
utils/spacewalk-utils.spec | 5 ++++-
3 files changed, 6 insertions(+), 3 deletions(-)
New commits:
commit e2bdc5b30430c320872f42aaff1d05d8154b7b5f
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Jul 13 09:47:43 2011 +0200
Automatic commit of package [spacewalk-utils] release [1.5.4-1].
diff --git a/rel-eng/packages/spacewalk-utils b/rel-eng/packages/spacewalk-utils
index efa52bd..23cd370 100644
--- a/rel-eng/packages/spacewalk-utils
+++ b/rel-eng/packages/spacewalk-utils
@@ -1 +1 @@
-1.5.3-1 utils/
+1.5.4-1 utils/
diff --git a/utils/spacewalk-utils.spec b/utils/spacewalk-utils.spec
index 40c3f42..8956790 100644
--- a/utils/spacewalk-utils.spec
+++ b/utils/spacewalk-utils.spec
@@ -1,7 +1,7 @@
%define rhnroot %{_prefix}/share/rhn
Name: spacewalk-utils
-Version: 1.5.3
+Version: 1.5.4
Release: 1%{?dist}
Summary: Utilities that may be run against a Spacewalk server.
@@ -69,6 +69,9 @@ rm -rf $RPM_BUILD_ROOT
%changelog
+* Wed Jul 13 2011 Jan Pazdziora 1.5.4-1
+- We get either undefined value or BLOB for the blob columns type.
+
* Fri May 20 2011 Michael Mraka <michael.mraka(a)redhat.com> 1.5.3-1
- fix broken (non-utf8) changelog entries
commit fe0f87bd13c9c4e9479a85cedc8e5c5f06720d9a
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Tue Jul 12 16:13:25 2011 +0200
We get either undefined value or BLOB for the blob columns type.
diff --git a/utils/spacewalk-dump-schema b/utils/spacewalk-dump-schema
index e391111..0068ed4 100755
--- a/utils/spacewalk-dump-schema
+++ b/utils/spacewalk-dump-schema
@@ -115,7 +115,7 @@ sub process_table {
if (ref $row->[$i] and ref $row->[$i] eq 'ARRAY') { # user types
no warnings 'uninitialized';
$row->[$i] = "(@{[ join ',', @{$row->[$i]} ]})";
- } elsif ($types[$i] eq 'unknown') { # blobs
+ } elsif ($types[$i] eq 'unknown' or $types[$i] eq 'BLOB') { # blobs
$row->[$i] =~ s!(.)! sprintf "\\\\%03o", ord($1) !seg;
} else {
$row->[$i] =~ s!([\x00-\x1f\x5c])! sprintf "\\x%02x", ord($1) !seg;
12 years, 9 months