client/rhel rel-eng/packages
by Martin Minar
client/rhel/rhnlib/rhnlib.spec | 6 +++++-
rel-eng/packages/rhnlib | 2 +-
2 files changed, 6 insertions(+), 2 deletions(-)
New commits:
commit 8b2913dc5041a5cf343a326513df0828508de4ac
Author: Martin Minar <mminar(a)redhat.com>
Date: Wed Nov 2 10:55:00 2011 +0100
Automatic commit of package [rhnlib] release [2.5.48-1].
diff --git a/client/rhel/rhnlib/rhnlib.spec b/client/rhel/rhnlib/rhnlib.spec
index 12db525..3e93703 100644
--- a/client/rhel/rhnlib/rhnlib.spec
+++ b/client/rhel/rhnlib/rhnlib.spec
@@ -4,7 +4,7 @@ Summary: Python libraries for the RHN project
Name: rhnlib
URL: https://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
-Version: 2.5.47
+Version: 2.5.48
Release: 1%{?dist}
Group: Development/Libraries
@@ -61,6 +61,10 @@ rm -rf $RPM_BUILD_ROOT
%{python_sitelib}/*
%changelog
+* Wed Nov 02 2011 Martin Minar <mminar(a)redhat.com> 2.5.48-1
+- Change PASS percentage after few attempts and print percentage in case of
+ failure (jhutar(a)redhat.com)
+
* Fri Oct 28 2011 Jan Pazdziora 2.5.47-1
- Do not rely on exact amount of memomory when determinig PASS/FAIL
(jhutar(a)redhat.com)
diff --git a/rel-eng/packages/rhnlib b/rel-eng/packages/rhnlib
index 9816c82..d0fd9e8 100644
--- a/rel-eng/packages/rhnlib
+++ b/rel-eng/packages/rhnlib
@@ -1 +1 @@
-2.5.47-1 client/rhel/rhnlib/
+2.5.48-1 client/rhel/rhnlib/
12 years, 5 months
Changes to 'refs/tags/spacewalk-remote-utils-1.6.3-1'
by aparsons
Tag 'spacewalk-remote-utils-1.6.3-1' created by Aron Parsons <parsonsa(a)bit-sys.com> at 2011-11-01 22:03 +0000
Tagging package [spacewalk-remote-utils] version [1.6.3-1] in directory [client/tools/spacewalk-remote-utils/].
Changes since rhn-client-tools-1.6.31-1:
Aron Parsons (2):
added spacewalk-add-providers script to spacewalk-remote-utils package
Automatic commit of package [spacewalk-remote-utils] release [1.6.3-1].
---
client/tools/spacewalk-remote-utils/spacewalk-add-providers/spacewalk-add-providers | 95 ++++++++++
client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec | 8
rel-eng/packages/spacewalk-remote-utils | 2
3 files changed, 103 insertions(+), 2 deletions(-)
---
12 years, 5 months
2 commits - client/tools rel-eng/packages
by aparsons
client/tools/spacewalk-remote-utils/spacewalk-add-providers/spacewalk-add-providers | 95 ++++++++++
client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec | 8
rel-eng/packages/spacewalk-remote-utils | 2
3 files changed, 103 insertions(+), 2 deletions(-)
New commits:
commit 6e05f1cf2a8e21ef3bf54623354177f8232b5e6f
Author: Aron Parsons <parsonsa(a)bit-sys.com>
Date: Tue Nov 1 18:03:36 2011 -0400
Automatic commit of package [spacewalk-remote-utils] release [1.6.3-1].
diff --git a/client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec b/client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec
index 7ebb9e9..af34f8e 100644
--- a/client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec
+++ b/client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec
@@ -4,7 +4,7 @@
%endif
Name: spacewalk-remote-utils
-Version: 1.6.2
+Version: 1.6.3
Release: 1%{?dist}
Summary: Utilities to interact with a RHN Satellite or Spacewalk server remotely.
@@ -59,6 +59,10 @@ docbook2man ./spacewalk-create-channel/doc/spacewalk-create-channel.sgml -o ./sp
%doc %{_mandir}/man1/spacewalk-create-channel.1.gz
%changelog
+* Tue Nov 01 2011 Aron Parsons <parsonsa(a)bit-sys.com> 1.6.3-1
+- added spacewalk-add-providers script to spacewalk-remote-utils package
+ (parsonsa(a)bit-sys.com)
+
* Tue Aug 02 2011 Tomas Lestach <tlestach(a)redhat.com> 1.6.2-1
- 727531 - adding RHEL5.7 channel definitions (tlestach(a)redhat.com)
diff --git a/rel-eng/packages/spacewalk-remote-utils b/rel-eng/packages/spacewalk-remote-utils
index 4bdb76f..8d0fe3e 100644
--- a/rel-eng/packages/spacewalk-remote-utils
+++ b/rel-eng/packages/spacewalk-remote-utils
@@ -1 +1 @@
-1.6.2-1 client/tools/spacewalk-remote-utils/
+1.6.3-1 client/tools/spacewalk-remote-utils/
commit cf9f366ebd982c3b0a65c63774e616d2b651db8d
Author: Aron Parsons <parsonsa(a)bit-sys.com>
Date: Tue Nov 1 18:00:40 2011 -0400
added spacewalk-add-providers script to spacewalk-remote-utils package
diff --git a/client/tools/spacewalk-remote-utils/spacewalk-add-providers/spacewalk-add-providers b/client/tools/spacewalk-remote-utils/spacewalk-add-providers/spacewalk-add-providers
new file mode 100755
index 0000000..16d78b4
--- /dev/null
+++ b/client/tools/spacewalk-remote-utils/spacewalk-add-providers/spacewalk-add-providers
@@ -0,0 +1,95 @@
+#!/usr/bin/python
+#
+# Author: Aron Parsons <parsonsa(a)bit-sys.com>
+#
+
+from optparse import Option, OptionParser
+import logging, os, shutil, sys, tempfile, xmlrpclib
+import gpgme
+
+opts = [ Option('-u', '--username'),
+ Option('-p', '--password'),
+ Option('-s', '--server'),
+ Option('-t', '--test', action = 'store_true'),
+ Option('-d', '--debug', action = 'store_true')
+ ]
+
+usage = '%prog [options] GPG_KEY ...'
+
+(options, args) = OptionParser(option_list = opts, usage = usage).parse_args()
+
+if options.debug:
+ level = logging.DEBUG
+else:
+ level = logging.INFO
+
+logging.basicConfig(level = level, format = '%(levelname)s: %(message)s')
+
+# warn the user that they're in test mode
+if options.test:
+ logging.info('TEST MODE: no providers will be added to the server')
+
+if not options.server:
+ options.server = 'localhost'
+
+if not options.username or not options.password:
+ logging.error('--username or --password missing')
+ sys.exit(1)
+
+if not len(args):
+ logging.error('You must supply at least one key file')
+ sys.exit(1)
+
+# login to the Spacewalk server
+try:
+ client = xmlrpclib.Server('https://%s/rpc/api' % options.server)
+ session = client.auth.login(options.username, options.password)
+except Exception, e:
+ if options.debug: logging.exception(e)
+ logging.error('Failed to login to the server')
+ sys.exit(1)
+
+for key_file in args:
+ logging.debug('Processing %s' % key_file)
+
+ if not os.path.exists(key_file):
+ logging.error('%s does not exist' % key_file)
+ continue
+
+ # use a temporary directory for the GPG keyring
+ gpg_home = tempfile.mkdtemp()
+ logging.debug('Using %s as the GPG directory' % gpg_home)
+ os.environ['GNUPGHOME'] = gpg_home
+
+ # read the key's provider and ID
+ try:
+ ctx = gpgme.Context()
+
+ result = ctx.import_(open(key_file, 'rb'))
+
+ for key in ctx.keylist():
+ provider_name = key.uids[0].name
+ key_id = key.subkeys[0].keyid.lower()
+
+ # remove our temporary GPG home
+ shutil.rmtree(gpg_home)
+ except Exception, e:
+ if options.debug: logging.exception(e)
+ logging.error('Failed to read the key: %s' % key_file)
+ continue
+
+ try:
+ logging.info('Adding %s as %s' % (key_id, provider_name))
+
+ if options.test: continue
+
+ client.packages.provider.associateKey(session,
+ provider_name,
+ key_id,
+ 'gpg')
+ except Exception, e:
+ if options.debug: logging.exception(e)
+ logging.error('Failed to add the key to the server: %s' % key_file)
+ continue
+
+# vim:ts=4:expandtab:
diff --git a/client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec b/client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec
index e073e13..7ebb9e9 100644
--- a/client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec
+++ b/client/tools/spacewalk-remote-utils/spacewalk-remote-utils.spec
@@ -36,6 +36,7 @@ docbook2man ./spacewalk-create-channel/doc/spacewalk-create-channel.sgml -o ./sp
%{__rm} -rf %{buildroot}
%{__mkdir_p} %{buildroot}/%{_bindir}
+%{__install} -p -m0755 spacewalk-add-providers/spacewalk-add-providers %{buildroot}/%{_bindir}/
%{__install} -p -m0755 spacewalk-create-channel/spacewalk-create-channel %{buildroot}/%{_bindir}/
%{__mkdir_p} %{buildroot}/%{_datadir}/rhn/channel-data
@@ -49,6 +50,7 @@ docbook2man ./spacewalk-create-channel/doc/spacewalk-create-channel.sgml -o ./sp
%files
%defattr(-,root,root,-)
+%{_bindir}/spacewalk-add-providers
%{_bindir}/spacewalk-create-channel
#%{python_sitelib}/spacecmd/
%{_datadir}/rhn/channel-data/
12 years, 5 months
Changes to 'refs/tags/rhn-client-tools-1.6.31-1'
by Miroslav Suchý
Tag 'rhn-client-tools-1.6.31-1' created by Miroslav Suchý <msuchy(a)redhat.com> at 2011-11-01 15:52 +0000
Tagging package [rhn-client-tools] version [1.6.31-1] in directory [client/rhel/rhn-client-tools/].
Changes since rhnclient-0.14-1:
Christian Berendt (1):
introducing name for scripts in kickstart profiles in the webinterface
Miroslav Suchý (2):
595837 - properly handle two exceptions
Automatic commit of package [rhn-client-tools] release [1.6.31-1].
---
client/rhel/rhn-client-tools/rhn-client-tools.spec | 5 ++
client/rhel/rhn-client-tools/src/up2date_client/rhncli.py | 2 -
java/code/src/com/redhat/rhn/common/db/datasource/xml/General_queries.xml | 2 -
java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.hbm.xml | 1
java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.java | 18 +++++++++
java/code/src/com/redhat/rhn/domain/kickstart/builder/KickstartBuilder.java | 2 -
java/code/src/com/redhat/rhn/frontend/action/kickstart/BaseKickstartScriptAction.java | 6 ++-
java/code/src/com/redhat/rhn/frontend/dto/kickstart/ScriptDto.java | 17 ++++++++
java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_en_US.xml | 14 +++++++
java/code/src/com/redhat/rhn/manager/kickstart/BaseKickstartScriptCommand.java | 20 +++++++++-
java/code/src/com/redhat/rhn/manager/kickstart/test/KickstartScriptCommandTest.java | 4 +-
java/code/webapp/WEB-INF/pages/kickstart/script-form.jspf | 8 ++++
java/code/webapp/WEB-INF/pages/kickstart/scriptdelete.jsp | 8 ++++
java/code/webapp/WEB-INF/pages/kickstart/scripts.jsp | 3 +
java/code/webapp/WEB-INF/struts-config.xml | 1
rel-eng/packages/rhn-client-tools | 2 -
schema/spacewalk/common/tables/rhnKickstartScript.sql | 1
schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.oracle | 1
schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.postgresql | 2 +
19 files changed, 108 insertions(+), 9 deletions(-)
---
12 years, 5 months
2 commits - client/rhel rel-eng/packages
by Miroslav Suchý
client/rhel/rhn-client-tools/rhn-client-tools.spec | 5 ++++-
client/rhel/rhn-client-tools/src/up2date_client/rhncli.py | 2 +-
rel-eng/packages/rhn-client-tools | 2 +-
3 files changed, 6 insertions(+), 3 deletions(-)
New commits:
commit c64c30fc351198a1439a65abdd7400612b70a0cd
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Tue Nov 1 16:52:01 2011 +0100
Automatic commit of package [rhn-client-tools] release [1.6.31-1].
diff --git a/client/rhel/rhn-client-tools/rhn-client-tools.spec b/client/rhel/rhn-client-tools/rhn-client-tools.spec
index bab960c..f5494e3 100644
--- a/client/rhel/rhn-client-tools/rhn-client-tools.spec
+++ b/client/rhel/rhn-client-tools/rhn-client-tools.spec
@@ -4,7 +4,7 @@ Group: System Environment/Base
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
URL: https://fedorahosted.org/spacewalk
Name: rhn-client-tools
-Version: 1.6.30
+Version: 1.6.31
Release: 1%{?dist}
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
@@ -334,6 +334,9 @@ make -f Makefile.rhn-client-tools test
%endif
%changelog
+* Tue Nov 01 2011 Miroslav Suchý 1.6.31-1
+- 595837 - properly handle two exceptions (msuchy(a)redhat.com)
+
* Tue Nov 01 2011 Tomas Lestach <tlestach(a)redhat.com> 1.6.30-1
- 706148 - fix setting uri (luvilla(a)redhat.com)
diff --git a/rel-eng/packages/rhn-client-tools b/rel-eng/packages/rhn-client-tools
index eda2c55..960f8b1 100644
--- a/rel-eng/packages/rhn-client-tools
+++ b/rel-eng/packages/rhn-client-tools
@@ -1 +1 @@
-1.6.30-1 client/rhel/rhn-client-tools/
+1.6.31-1 client/rhel/rhn-client-tools/
commit 497663177760d7822ee8019367b92f998a77be96
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Tue Nov 1 16:14:41 2011 +0100
595837 - properly handle two exceptions
diff --git a/client/rhel/rhn-client-tools/src/up2date_client/rhncli.py b/client/rhel/rhn-client-tools/src/up2date_client/rhncli.py
index ac8df42..efea5a2 100644
--- a/client/rhel/rhn-client-tools/src/up2date_client/rhncli.py
+++ b/client/rhel/rhn-client-tools/src/up2date_client/rhncli.py
@@ -91,7 +91,7 @@ class RhnCli(object):
sys.stderr.write(_("A common cause of this error is the system time being incorrect. " \
"Verify that the time on this system is correct.\n"))
sys.exit(1)
- except SSL.SysCallError, socket.error:
+ except (SSL.SysCallError, socket.error), e:
sys.stderr.write("OpenSSL.SSL.SysCallError: %s\n" % str(e))
sys.exit(2)
except crypto.Error, e:
12 years, 5 months
java/code schema/spacewalk
by Tomas Lestach
java/code/src/com/redhat/rhn/common/db/datasource/xml/General_queries.xml | 2 -
java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.hbm.xml | 1
java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.java | 18 +++++++++
java/code/src/com/redhat/rhn/domain/kickstart/builder/KickstartBuilder.java | 2 -
java/code/src/com/redhat/rhn/frontend/action/kickstart/BaseKickstartScriptAction.java | 6 ++-
java/code/src/com/redhat/rhn/frontend/dto/kickstart/ScriptDto.java | 17 ++++++++
java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_en_US.xml | 14 +++++++
java/code/src/com/redhat/rhn/manager/kickstart/BaseKickstartScriptCommand.java | 20 +++++++++-
java/code/src/com/redhat/rhn/manager/kickstart/test/KickstartScriptCommandTest.java | 4 +-
java/code/webapp/WEB-INF/pages/kickstart/script-form.jspf | 8 ++++
java/code/webapp/WEB-INF/pages/kickstart/scriptdelete.jsp | 8 ++++
java/code/webapp/WEB-INF/pages/kickstart/scripts.jsp | 3 +
java/code/webapp/WEB-INF/struts-config.xml | 1
schema/spacewalk/common/tables/rhnKickstartScript.sql | 1
schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.oracle | 1
schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.postgresql | 2 +
16 files changed, 102 insertions(+), 6 deletions(-)
New commits:
commit be7996f4740fd642b1c92068ac96b8abfbd1f1b4
Author: Christian Berendt <berendt(a)b1-systems.de>
Date: Tue Nov 1 15:34:26 2011 +0100
introducing name for scripts in kickstart profiles in the webinterface
diff --git a/java/code/src/com/redhat/rhn/common/db/datasource/xml/General_queries.xml b/java/code/src/com/redhat/rhn/common/db/datasource/xml/General_queries.xml
index 6f6be26..b4f68eb 100644
--- a/java/code/src/com/redhat/rhn/common/db/datasource/xml/General_queries.xml
+++ b/java/code/src/com/redhat/rhn/common/db/datasource/xml/General_queries.xml
@@ -64,7 +64,7 @@ ORDER BY KS.label, KS.id
<mode name="scripts_for_kickstart" class="com.redhat.rhn.frontend.dto.kickstart.ScriptDto">
<query params="kickstart_id">
- SELECT KS.id, KS.script_type, KS.chroot, KS.interpreter
+ SELECT KS.id, KS.script_type, KS.chroot, KS.interpreter, KS.script_name
FROM rhnKickstartScript KS
WHERE KS.kickstart_id = :kickstart_id
</query>
diff --git a/java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.hbm.xml b/java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.hbm.xml
index 9e495c5..376ea87 100644
--- a/java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.hbm.xml
+++ b/java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.hbm.xml
@@ -16,6 +16,7 @@ PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
<property name="chroot" column="chroot" not-null="true" type="string" length="1" />
<property name="raw" column="raw_script" not-null="true" type="yes_no" />
<property name="interpreter" column="interpreter" type="string" length="80" />
+ <property name="scriptName" column="script_name" not-null="true" type="string" length="40" />
<property name="data" column="data" type="binary" />
<property name="created" column="created" not-null="true"
type="timestamp" insert="false" update="false"/>
diff --git a/java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.java b/java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.java
index 9bee435..94fa065 100644
--- a/java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.java
+++ b/java/code/src/com/redhat/rhn/domain/kickstart/KickstartScript.java
@@ -32,6 +32,7 @@ public class KickstartScript implements Comparable<KickstartScript> {
private String scriptType;
private String chroot;
private String interpreter;
+ private String scriptName;
private byte[] data;
private Date created;
private Date modified;
@@ -48,6 +49,22 @@ public class KickstartScript implements Comparable<KickstartScript> {
}
/**
+ * Getter for scriptName
+ * @return String to get
+ */
+ public String getScriptName() {
+ return this.scriptName;
+ }
+
+ /**
+ * Setter for scriptName
+ * @param scriptNameIn to set
+ */
+ public void setScriptName(String scriptNameIn) {
+ this.scriptName = scriptNameIn;
+ }
+
+ /**
* Getter for id
* @return Long to get
*/
@@ -214,6 +231,7 @@ public class KickstartScript implements Comparable<KickstartScript> {
public KickstartScript deepCopy(KickstartData ksDataIn) {
KickstartScript cloned = new KickstartScript();
cloned.setChroot(this.getChroot());
+ cloned.setScriptName(this.getScriptName());
cloned.setData(this.getData());
cloned.setInterpreter(this.getInterpreter());
cloned.setKsdata(ksDataIn);
diff --git a/java/code/src/com/redhat/rhn/domain/kickstart/builder/KickstartBuilder.java b/java/code/src/com/redhat/rhn/domain/kickstart/builder/KickstartBuilder.java
index b92155e..b5f7721 100644
--- a/java/code/src/com/redhat/rhn/domain/kickstart/builder/KickstartBuilder.java
+++ b/java/code/src/com/redhat/rhn/domain/kickstart/builder/KickstartBuilder.java
@@ -328,7 +328,7 @@ public class KickstartBuilder {
type = KickstartScript.TYPE_POST;
}
- scriptCommand.setScript(interpreter, buf.toString(), type, chroot, false);
+ scriptCommand.setScript(interpreter, buf.toString(), type, chroot, false, null);
scriptCommand.store();
}
diff --git a/java/code/src/com/redhat/rhn/frontend/action/kickstart/BaseKickstartScriptAction.java b/java/code/src/com/redhat/rhn/frontend/action/kickstart/BaseKickstartScriptAction.java
index ba54031..dfe82a7 100644
--- a/java/code/src/com/redhat/rhn/frontend/action/kickstart/BaseKickstartScriptAction.java
+++ b/java/code/src/com/redhat/rhn/frontend/action/kickstart/BaseKickstartScriptAction.java
@@ -35,6 +35,7 @@ import javax.servlet.http.HttpServletRequest;
*/
public abstract class BaseKickstartScriptAction extends BaseKickstartEditAction {
+ public static final String SCRIPTNAME = "script_name";
public static final String CONTENTS = "contents";
public static final String LANGUAGE = "language";
public static final String TYPE = "type";
@@ -73,11 +74,13 @@ public abstract class BaseKickstartScriptAction extends BaseKickstartEditAction
return new ValidatorError("kickstart.script.toolarge",
LocalizationService.getInstance().formatNumber(new Long(maxLength)));
}
+
kssc.setScript(form.getString(LANGUAGE),
scriptValue,
form.getString(TYPE),
chroot,
- template);
+ template,
+ form.getString(SCRIPTNAME));
return null;
}
@@ -100,6 +103,7 @@ public abstract class BaseKickstartScriptAction extends BaseKickstartEditAction
BaseKickstartScriptCommand kssc = (BaseKickstartScriptCommand) cmd;
form.set(CONTENTS, kssc.getContents());
+ form.set(SCRIPTNAME, kssc.getScriptName());
form.set(LANGUAGE, kssc.getLanguage());
form.set(TYPE, kssc.getType());
form.set(NOCHROOT, kssc.getNoChrootVal());
diff --git a/java/code/src/com/redhat/rhn/frontend/dto/kickstart/ScriptDto.java b/java/code/src/com/redhat/rhn/frontend/dto/kickstart/ScriptDto.java
index ca86155..9ae87c4 100644
--- a/java/code/src/com/redhat/rhn/frontend/dto/kickstart/ScriptDto.java
+++ b/java/code/src/com/redhat/rhn/frontend/dto/kickstart/ScriptDto.java
@@ -30,6 +30,7 @@ public class ScriptDto extends BaseDto {
private String chroot;
private String interpreter;
private int position;
+ private String scriptName;
private static final String BASH = "bash";
private static final String PRE = "Pre";
private static final String POST = "Post";
@@ -37,6 +38,22 @@ public class ScriptDto extends BaseDto {
/**
*
+ * @return scriptName
+ */
+ public String getScriptName() {
+ return scriptName;
+ }
+
+ /**
+ *
+ * @param scriptNameIn to set
+ */
+ public void setScriptName(String scriptNameIn) {
+ this.scriptName = scriptNameIn;
+ }
+
+ /**
+ *
* @return chroot
*/
public String getChroot() {
diff --git a/java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_en_US.xml b/java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_en_US.xml
index 3ff73ba..d1c7227 100644
--- a/java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_en_US.xml
+++ b/java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_en_US.xml
@@ -10571,6 +10571,13 @@ Please note that some manual configuration of these scripts may still be require
</context-group>
</trans-unit>
+ <trans-unit id="kickstartscript.jsp.scriptname">
+ <source>Script Name</source>
+ <context-group name="ctx">
+ <context context-type="sourcefile">/rhn/kickstart/Scripts</context>
+ </context-group>
+ </trans-unit>
+
<trans-unit id="kickstartscript.jsp.language">
<source>Scripting Language</source>
<context-group name="ctx">
@@ -11646,6 +11653,13 @@ Please note that some manual configuration of these scripts may still be require
</context-group>
</trans-unit>
+ <trans-unit id="kickstart.script.scriptname">
+ <source>Script Name</source>
+ <context-group name="ctx">
+ <context context-type="sourcefile">/rhn/kickstart/KickstartScriptEdit.do</context>
+ </context-group>
+ </trans-unit>
+
<trans-unit id="kickstart.script.contents">
<source>Script Contents</source>
<context-group name="ctx">
diff --git a/java/code/src/com/redhat/rhn/manager/kickstart/BaseKickstartScriptCommand.java b/java/code/src/com/redhat/rhn/manager/kickstart/BaseKickstartScriptCommand.java
index 0ae0ba6..46b78be 100644
--- a/java/code/src/com/redhat/rhn/manager/kickstart/BaseKickstartScriptCommand.java
+++ b/java/code/src/com/redhat/rhn/manager/kickstart/BaseKickstartScriptCommand.java
@@ -61,9 +61,11 @@ public class BaseKickstartScriptCommand extends BaseKickstartCommand {
* @param typeIn of script (KickstartScript.TYPE_POST or KickstartScript.TYPE_PRE)
* @param chrootIn value of chroot ("Y" or "N")
* @param templatize whether to templatize the script or not
+ * @param scriptName name of the script
*/
public void setScript(String language, String contentsIn,
- String typeIn, String chrootIn, boolean templatize) {
+ String typeIn, String chrootIn, boolean templatize,
+ String scriptName) {
if (!typeIn.equals(KickstartScript.TYPE_POST) &&
!typeIn.equals(KickstartScript.TYPE_PRE)) {
throw new IllegalArgumentException("Unknown script type: " + typeIn);
@@ -86,10 +88,18 @@ public class BaseKickstartScriptCommand extends BaseKickstartCommand {
language = language.trim();
}
+ if (StringUtils.isBlank(scriptName)) {
+ scriptName = null;
+ }
+ else {
+ scriptName = scriptName.trim();
+ }
+
this.script.setInterpreter(language);
this.script.setScriptType(typeIn);
this.script.setChroot(chrootIn);
this.script.setRaw(!templatize); //template is the ! of raw
+ this.script.setScriptName(scriptName);
}
/**
@@ -110,6 +120,14 @@ public class BaseKickstartScriptCommand extends BaseKickstartCommand {
}
/**
+ * Get the name of this script
+ * @return String
+ */
+ public String getScriptName() {
+ return this.script.getScriptName();
+ }
+
+ /**
* Get the type of Script this is. See KickstartScript.TYPE_PRE, TYPE_POST.
* Defaults to KickstartScript.TYPE_PRE
*
diff --git a/java/code/src/com/redhat/rhn/manager/kickstart/test/KickstartScriptCommandTest.java b/java/code/src/com/redhat/rhn/manager/kickstart/test/KickstartScriptCommandTest.java
index 7b9d363..e8a1fcf 100644
--- a/java/code/src/com/redhat/rhn/manager/kickstart/test/KickstartScriptCommandTest.java
+++ b/java/code/src/com/redhat/rhn/manager/kickstart/test/KickstartScriptCommandTest.java
@@ -52,7 +52,7 @@ public class KickstartScriptCommandTest extends BaseKickstartCommandTestCase {
assertNotNull(cmd.getKickstartData().getScripts());
KickstartScript kss = cmd.getScript();
assertNotNull(kss.getScriptType());
- cmd.setScript(language, contents, KickstartScript.TYPE_PRE, chroot, false);
+ cmd.setScript(language, contents, KickstartScript.TYPE_PRE, chroot, false, null);
cmd.store();
ksdata = (KickstartData) reload(ksdata);
assertEquals(contents, cmd.getContents());
@@ -67,7 +67,7 @@ public class KickstartScriptCommandTest extends BaseKickstartCommandTestCase {
String chroot = "Y";
KickstartScriptEditCommand cmd =
new KickstartScriptEditCommand(ksdata.getId(), kss.getId(), user);
- cmd.setScript(language, contents, KickstartScript.TYPE_PRE, chroot, true);
+ cmd.setScript(language, contents, KickstartScript.TYPE_PRE, chroot, true, null);
cmd.store();
ksdata = (KickstartData) reload(ksdata);
assertEquals(contents, cmd.getContents());
diff --git a/java/code/webapp/WEB-INF/pages/kickstart/script-form.jspf b/java/code/webapp/WEB-INF/pages/kickstart/script-form.jspf
index 15ea3e3..57ded71 100644
--- a/java/code/webapp/WEB-INF/pages/kickstart/script-form.jspf
+++ b/java/code/webapp/WEB-INF/pages/kickstart/script-form.jspf
@@ -21,6 +21,14 @@
</tr>
<tr>
<th>
+ <bean:message key="kickstart.script.scriptname"/>
+ </th>
+ <td>
+ <html:text property="script_name" maxlength="40" size="20" /><br/>
+ </td>
+ </tr>
+ <tr>
+ <th>
<rhn:required-field key="kickstart.script.contents"/>
</th>
<td>
diff --git a/java/code/webapp/WEB-INF/pages/kickstart/scriptdelete.jsp b/java/code/webapp/WEB-INF/pages/kickstart/scriptdelete.jsp
index 6f54e05..f239a49 100644
--- a/java/code/webapp/WEB-INF/pages/kickstart/scriptdelete.jsp
+++ b/java/code/webapp/WEB-INF/pages/kickstart/scriptdelete.jsp
@@ -30,6 +30,14 @@
</tr>
<tr>
<th>
+ <bean:message key="kickstart.script.scriptname"/>
+ </th>
+ <td>
+ ${ksscript.scriptName}
+ </td>
+ </tr>
+ <tr>
+ <th>
<bean:message key="kickstart.script.language"/>
</th>
<td>
diff --git a/java/code/webapp/WEB-INF/pages/kickstart/scripts.jsp b/java/code/webapp/WEB-INF/pages/kickstart/scripts.jsp
index 3f1158f..8be640b 100644
--- a/java/code/webapp/WEB-INF/pages/kickstart/scripts.jsp
+++ b/java/code/webapp/WEB-INF/pages/kickstart/scripts.jsp
@@ -41,6 +41,9 @@
<rhn:column header="kickstartscript.jsp.scriptnum">
<a href="/rhn/kickstart/KickstartScriptEdit.do?kssid=${current.id}&ksid=${ksdata.id}"><bean:message key="kickstartscript.jsp.script"/> ${current.position}</a>
</rhn:column>
+ <rhn:column header="kickstartscript.jsp.scriptname">
+ <a href="/rhn/kickstart/KickstartScriptEdit.do?kssid=${current.id}&ksid=${ksdata.id}">${current.scriptName}</a>
+ </rhn:column>
<rhn:column header="kickstartscript.jsp.language">
${current.interpreter}
</rhn:column>
diff --git a/java/code/webapp/WEB-INF/struts-config.xml b/java/code/webapp/WEB-INF/struts-config.xml
index f991165..97ddfc0 100644
--- a/java/code/webapp/WEB-INF/struts-config.xml
+++ b/java/code/webapp/WEB-INF/struts-config.xml
@@ -680,6 +680,7 @@
<form-bean name="kickstartScriptForm"
type="com.redhat.rhn.frontend.struts.ScrubbingDynaActionForm">
<form-property name="language" type="java.lang.String" />
+ <form-property name="script_name" type="java.lang.String" />
<form-property name="contents" type="java.lang.String" />
<form-property name="type" type="java.lang.String" />
<form-property name="nochroot" type="java.lang.Boolean" />
diff --git a/schema/spacewalk/common/tables/rhnKickstartScript.sql b/schema/spacewalk/common/tables/rhnKickstartScript.sql
index 1be4bc8..070c70b 100644
--- a/schema/spacewalk/common/tables/rhnKickstartScript.sql
+++ b/schema/spacewalk/common/tables/rhnKickstartScript.sql
@@ -17,6 +17,7 @@
CREATE TABLE rhnKickstartScript
(
id NUMBER NOT NULL,
+ script_name VARCHAR2(40),
kickstart_id NUMBER NOT NULL
CONSTRAINT rhn_ksscript_ksid_fk
REFERENCES rhnKSData (id)
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.oracle b/schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.oracle
new file mode 100644
index 0000000..3595b18
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.oracle
@@ -0,0 +1 @@
+alter table rhnKickstartScript add script_name varchar2(40);
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.postgresql b/schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.postgresql
new file mode 100644
index 0000000..b5726e8
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.5-to-spacewalk-schema-1.6/101-add_rhnKickstartScript_scriptname.sql.postgresql
@@ -0,0 +1,2 @@
+-- oracle equivalent source sha1 ad2857013352bc8584ecc60a413b6d257f94ccd6
+alter table rhnKickstartScript add column script_name varchar2(40);
12 years, 5 months
Changes to 'refs/tags/rhnclient-0.14-1'
by Michael Mraka
Tag 'rhnclient-0.14-1' created by Michael Mraka <michael.mraka(a)redhat.com> at 2011-11-01 14:18 +0000
Tagging package [rhnclient] version [0.14-1] in directory [client/solaris/rhnclient/].
Changes since rhn-client-tools-1.6.30-1:
Jan Hutar (1):
Change PASS percentage after few attempts and print percentage in case of failure
Michael Mraka (2):
744287 - fixed path so it isn't substituted in rpm2pkg
Automatic commit of package [rhnclient] release [0.14-1].
---
client/rhel/rhnlib/test/24-ssl-memleak.py | 4 ++--
client/solaris/rhnclient/rhnclient.spec | 5 ++++-
client/solaris/rhnclient/rhnsd.init | 2 +-
client/solaris/rhnclient/setup.py | 2 +-
rel-eng/packages/rhnclient | 2 +-
5 files changed, 9 insertions(+), 6 deletions(-)
---
12 years, 5 months
client/solaris rel-eng/packages
by Michael Mraka
client/solaris/rhnclient/rhnclient.spec | 5 ++++-
client/solaris/rhnclient/setup.py | 2 +-
rel-eng/packages/rhnclient | 2 +-
3 files changed, 6 insertions(+), 3 deletions(-)
New commits:
commit 302d10603cb103484eac9fb73c23ddc29de3c819
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Tue Nov 1 15:18:23 2011 +0100
Automatic commit of package [rhnclient] release [0.14-1].
diff --git a/client/solaris/rhnclient/rhnclient.spec b/client/solaris/rhnclient/rhnclient.spec
index de555df..b877268 100644
--- a/client/solaris/rhnclient/rhnclient.spec
+++ b/client/solaris/rhnclient/rhnclient.spec
@@ -5,7 +5,7 @@
Summary: Red Hat Network Client Utilities and Libraries
Name: rhnclient
Source0: %{name}-%{version}.tar.gz
-Version: 0.13
+Version: 0.14
Release: 1
License: GPLv2
Group: Development/Libraries
@@ -65,6 +65,9 @@ rm -rf $RPM_BUILD_ROOT
#%doc ChangeLog COPYING README TODO
%changelog
+* Tue Nov 01 2011 Michael Mraka <michael.mraka(a)redhat.com> 0.14-1
+- 744287 - fixed path so it isn't substituted in rpm2pkg
+
* Wed Mar 30 2011 Miroslav Suchý 0.13-1
- 683200 - instead of encodings.idna use wrapper from rhn.connections, which
workaround corner cases
diff --git a/client/solaris/rhnclient/setup.py b/client/solaris/rhnclient/setup.py
index 8c7cea3..44e392b 100644
--- a/client/solaris/rhnclient/setup.py
+++ b/client/solaris/rhnclient/setup.py
@@ -6,7 +6,7 @@
from distutils.core import setup
setup(name = "rhnclient",
- version = "0.13",
+ version = "0.14",
description = "Red Hat Network Client Utilities and Libraries",
long_description = """\
Red Hat Network Client Utilities
diff --git a/rel-eng/packages/rhnclient b/rel-eng/packages/rhnclient
index aa8b6f8..5047cdc 100644
--- a/rel-eng/packages/rhnclient
+++ b/rel-eng/packages/rhnclient
@@ -1 +1 @@
-0.13-1 client/solaris/rhnclient/
+0.14-1 client/solaris/rhnclient/
12 years, 5 months
client/solaris
by Michael Mraka
client/solaris/rhnclient/rhnsd.init | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit fbf8f2f47251d782c8e960cf3ed6213f0b728189
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Tue Nov 1 15:14:46 2011 +0100
744287 - fixed path so it isn't substituted in rpm2pkg
diff --git a/client/solaris/rhnclient/rhnsd.init b/client/solaris/rhnclient/rhnsd.init
index 4eaa236..b4e4f45 100644
--- a/client/solaris/rhnclient/rhnsd.init
+++ b/client/solaris/rhnclient/rhnsd.init
@@ -30,7 +30,7 @@ RHNSD_PID=$PREFIX/var/run/rhnsd.pid
[ -f $PREFIX/etc/sysconfig/rhn/systemid ] || exit 0
# read configuration settings (interval) for rhnsd, if present.
-if [ -f $PREFIX//etc/sysconfig/rhn/rhnsd ]; then
+if [ -f $PREFIX/etc/sysconfig/rhn/rhnsd ]; then
. $PREFIX/etc/sysconfig/rhn/rhnsd
fi
12 years, 5 months
client/rhel
by Jan Hutař
client/rhel/rhnlib/test/24-ssl-memleak.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
New commits:
commit 5740d4c9f591956e65c5cb9a307f2eba0b3472b2
Author: Jan Hutar <jhutar(a)redhat.com>
Date: Tue Nov 1 14:19:14 2011 +0100
Change PASS percentage after few attempts and print percentage in case of failure
diff --git a/client/rhel/rhnlib/test/24-ssl-memleak.py b/client/rhel/rhnlib/test/24-ssl-memleak.py
index 88f9fed..6f59dc9 100755
--- a/client/rhel/rhnlib/test/24-ssl-memleak.py
+++ b/client/rhel/rhnlib/test/24-ssl-memleak.py
@@ -24,7 +24,7 @@ def main():
mem_usage = None
mem_usage_VmSize_max = None
mem_usage_VmSize_first = None
- mem_usage_VmSize_allowed_percent = 0.1 # [%] allowed gain of first -> max
+ mem_usage_VmSize_allowed_percent = 0.5 # [%] allowed gain of first -> max
for i in range(10000):
run_test(server_url, ca_cert)
if i % 100 == 0:
@@ -42,7 +42,7 @@ def main():
percent = float((mem_usage_VmSize_max - mem_usage_VmSize_first)) / (float(mem_usage_VmSize_first) / 100)
if percent >= mem_usage_VmSize_allowed_percent:
# Failure
- print "Test FAILS"
+ print "Test FAILS (%s %%)" % percent
return 1
print "Test PASSES"
12 years, 5 months