Changes to 'refs/tags/spacewalk-config-1.8.1-1'
by Jan Pazdziora
Tag 'spacewalk-config-1.8.1-1' created by Jan Pazdziora <jpazdziora(a)redhat.com> at 2012-03-21 13:30 +0000
Tagging package [spacewalk-config] version [1.8.1-1] in directory [spacewalk/config/].
Changes since spacewalk-web-1.8.5-1:
Jan Pazdziora (7):
The parameter/option is traceback_mail.
Avoid printing "None" when uninitialized value is found.
Reverting removal of traceback_mail.
Glob returns its input when file does not exist, filter it out.
Fixing regular_systems_in_channel_family for PostgreSQL.
Always regenerate server.pem for jabberd.
Automatic commit of package [spacewalk-config] release [1.8.1-1].
Shannon Hughes (1):
805275 - fix for configchannel.deployAllSystems
Simon Lukasik (2):
Set column name explicitly, because it varies by db backend.
Ensure the comparison uses correct type
Stephen Herr (1):
checkstyle fixes
---
backend/common/spacewalk-cfg-get | 2
backend/satellite_tools/satellite-sync.sgml | 2
java/code/src/com/redhat/rhn/common/db/datasource/xml/config_queries.xml | 20 +++
java/code/src/com/redhat/rhn/common/db/datasource/xml/scap_queries.xml | 2
java/code/src/com/redhat/rhn/frontend/xmlrpc/configchannel/ConfigChannelHandler.java | 2
java/code/src/com/redhat/rhn/manager/audit/ScapManager.java | 13 +-
java/code/src/com/redhat/rhn/manager/configuration/ConfigurationManager.java | 52 +++++++++-
java/code/src/com/redhat/rhn/manager/ssm/SsmManager.java | 14 +-
rel-eng/packages/spacewalk-config | 2
schema/spacewalk/spacewalk-schema-upgrade | 2
spacewalk/certs-tools/rhn_ssl_tool.py | 7 -
spacewalk/config/spacewalk-config.spec | 5
spacewalk/config/var/lib/rhn/rhn-satellite-prep/etc/rhn/rhn.conf | 1
web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml | 4
14 files changed, 99 insertions(+), 29 deletions(-)
---
12 years, 3 months
rel-eng/packages spacewalk/config
by Jan Pazdziora
rel-eng/packages/spacewalk-config | 2 +-
spacewalk/config/spacewalk-config.spec | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
New commits:
commit 60e2227c642164996f1fa663d24ee446139d1fee
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Mar 21 14:30:18 2012 +0100
Automatic commit of package [spacewalk-config] release [1.8.1-1].
diff --git a/rel-eng/packages/spacewalk-config b/rel-eng/packages/spacewalk-config
index c3667f8..6775d40 100644
--- a/rel-eng/packages/spacewalk-config
+++ b/rel-eng/packages/spacewalk-config
@@ -1 +1 @@
-1.7.2-1 spacewalk/config/
+1.8.1-1 spacewalk/config/
diff --git a/spacewalk/config/spacewalk-config.spec b/spacewalk/config/spacewalk-config.spec
index ff59c60..e77befb 100644
--- a/spacewalk/config/spacewalk-config.spec
+++ b/spacewalk/config/spacewalk-config.spec
@@ -1,6 +1,6 @@
Name: spacewalk-config
Summary: Spacewalk Configuration
-Version: 1.8.0
+Version: 1.8.1
Release: 1%{?dist}
URL: http://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
@@ -105,6 +105,9 @@ chgrp apache /etc/rhn /etc/rhn/rhn.conf /etc/rhn/cluster.ini 2> /dev/null || :
chmod o-rwx /etc/rhn/rhn.conf* /etc/rhn/cluster.ini* /etc/sysconfig/rhn/backup-* /var/lib/rhn/rhn-satellite-prep/* 2> /dev/null || :
%changelog
+* Wed Mar 21 2012 Jan Pazdziora 1.8.1-1
+- Reverting removal of traceback_mail.
+
* Tue Jan 31 2012 Jan Pazdziora 1.7.2-1
- Removing the web.debug_disable_database option -- it is not supported beyond
RHN::DB anyway.
12 years, 3 months
Changes to 'refs/tags/spacewalk-config-1.7.3-1'
by Jan Pazdziora
Tag 'spacewalk-config-1.7.3-1' created by Jan Pazdziora <jpazdziora(a)redhat.com> at 2012-03-21 11:15 +0000
Tagging package [spacewalk-config] version [1.7.3-1] in directory [spacewalk/config/].
Changes since spacewalk-setup-1.7.10-1:
Jan Pazdziora (1):
Automatic commit of package [spacewalk-config] release [1.7.3-1].
---
rel-eng/packages/spacewalk-config | 2 +-
spacewalk/config/spacewalk-config.spec | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
---
12 years, 3 months
Branch 'SPACEWALK-1.7' - rel-eng/packages spacewalk/config
by Jan Pazdziora
rel-eng/packages/spacewalk-config | 2 +-
spacewalk/config/spacewalk-config.spec | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
New commits:
commit 36cd7149eef86e4bbb930ab15111f5bd2340a502
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Mar 21 12:15:05 2012 +0100
Automatic commit of package [spacewalk-config] release [1.7.3-1].
diff --git a/rel-eng/packages/spacewalk-config b/rel-eng/packages/spacewalk-config
index c3667f8..47585fe 100644
--- a/rel-eng/packages/spacewalk-config
+++ b/rel-eng/packages/spacewalk-config
@@ -1 +1 @@
-1.7.2-1 spacewalk/config/
+1.7.3-1 spacewalk/config/
diff --git a/spacewalk/config/spacewalk-config.spec b/spacewalk/config/spacewalk-config.spec
index b3676bf..5609b13 100644
--- a/spacewalk/config/spacewalk-config.spec
+++ b/spacewalk/config/spacewalk-config.spec
@@ -1,6 +1,6 @@
Name: spacewalk-config
Summary: Spacewalk Configuration
-Version: 1.7.2
+Version: 1.7.3
Release: 1%{?dist}
URL: http://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
@@ -105,6 +105,9 @@ chgrp apache /etc/rhn /etc/rhn/rhn.conf /etc/rhn/cluster.ini 2> /dev/null || :
chmod o-rwx /etc/rhn/rhn.conf* /etc/rhn/cluster.ini* /etc/sysconfig/rhn/backup-* /var/lib/rhn/rhn-satellite-prep/* 2> /dev/null || :
%changelog
+* Wed Mar 21 2012 Jan Pazdziora 1.7.3-1
+- Reverting removal of traceback_mail.
+
* Tue Jan 31 2012 Jan Pazdziora 1.7.2-1
- Removing the web.debug_disable_database option -- it is not supported beyond
RHN::DB anyway.
12 years, 3 months
spacewalk/certs-tools
by Jan Pazdziora
spacewalk/certs-tools/rhn_ssl_tool.py | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
New commits:
commit 4dd65d747f04d5599fc832ebb00d41af4fd009c5
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Mar 21 12:01:15 2012 +0100
Always regenerate server.pem for jabberd.
diff --git a/spacewalk/certs-tools/rhn_ssl_tool.py b/spacewalk/certs-tools/rhn_ssl_tool.py
index c64698e..03713bc 100755
--- a/spacewalk/certs-tools/rhn_ssl_tool.py
+++ b/spacewalk/certs-tools/rhn_ssl_tool.py
@@ -936,12 +936,7 @@ def genServerRpm_dependencies(d):
dependencyCheck(server_cert)
dependencyCheck(server_cert_req)
- # if all the other dependencies exist except the server pem,
- # just generate it
- try:
- dependencyCheck(jabberd_ssl_cert)
- except FailedFileDependencyException:
- gen_jabberd_cert(d)
+ gen_jabberd_cert(d)
def genServerRpm(d, verbosity=0):
""" generates server's SSL key set RPM """
12 years, 3 months
java/code
by Tomas Lestach
java/code/src/com/redhat/rhn/common/db/datasource/xml/config_queries.xml | 20 +++
java/code/src/com/redhat/rhn/frontend/xmlrpc/configchannel/ConfigChannelHandler.java | 2
java/code/src/com/redhat/rhn/manager/configuration/ConfigurationManager.java | 52 +++++++++-
3 files changed, 71 insertions(+), 3 deletions(-)
New commits:
commit 1d8fa162998bbafec1dfc5c702b7580080f9834a
Author: Shannon Hughes <shughes(a)redhat.com>
Date: Wed Mar 21 10:42:42 2012 +0100
805275 - fix for configchannel.deployAllSystems
diff --git a/java/code/src/com/redhat/rhn/common/db/datasource/xml/config_queries.xml b/java/code/src/com/redhat/rhn/common/db/datasource/xml/config_queries.xml
index edd8b1f..db053c1 100644
--- a/java/code/src/com/redhat/rhn/common/db/datasource/xml/config_queries.xml
+++ b/java/code/src/com/redhat/rhn/common/db/datasource/xml/config_queries.xml
@@ -1284,6 +1284,26 @@ ORDER BY CFN.path
<elaborator name="file_name_elab" />
</mode>
+<mode name="file_names_for_system_channel" class="com.redhat.rhn.frontend.dto.ConfigFileNameDto">
+ <query params="sid, user_id">
+SELECT DISTINCT CFN.id, CFN.path
+ FROM rhnConfigFileName CFN, rhnServerConfigChannel SCC,
+ rhnConfigFile CF, rhnUserServerPerms USP,
+ rhnConfigChannel CC, rhnConfigChannelType CCT
+ WHERE SCC.server_id = :sid
+ AND CC.id = :ccid
+ AND USP.server_id = SCC.server_id
+ AND USP.user_id = :user_id
+ AND SCC.config_channel_id = CF.config_channel_id
+ AND SCC.config_channel_id = CC.id
+ AND CC.confchan_type_id = CCT.id
+ AND CCT.label != 'server_import'
+ AND CF.config_file_name_id = CFN.id
+ORDER BY CFN.path
+ </query>
+ <elaborator name="file_name_elab" />
+</mode>
+
<mode name="file_names_in_set" class="com.redhat.rhn.frontend.dto.ConfigFileNameDto">
<query params="user_id, name_set_label">
SELECT CFN.id, CFN.path
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/configchannel/ConfigChannelHandler.java b/java/code/src/com/redhat/rhn/frontend/xmlrpc/configchannel/ConfigChannelHandler.java
index 8c7f6e5..4be7f89 100644
--- a/java/code/src/com/redhat/rhn/frontend/xmlrpc/configchannel/ConfigChannelHandler.java
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/configchannel/ConfigChannelHandler.java
@@ -798,7 +798,7 @@ public class ConfigChannelHandler extends BaseHandler {
}
try {
- manager.deployConfiguration(loggedInUser, servers, date);
+ manager.deployConfiguration(loggedInUser, servers, channel, date);
}
catch (MissingCapabilityException e) {
throw new com.redhat.rhn.frontend.xmlrpc.MissingCapabilityException(
diff --git a/java/code/src/com/redhat/rhn/manager/configuration/ConfigurationManager.java b/java/code/src/com/redhat/rhn/manager/configuration/ConfigurationManager.java
index 90ccff3..6f82d20 100644
--- a/java/code/src/com/redhat/rhn/manager/configuration/ConfigurationManager.java
+++ b/java/code/src/com/redhat/rhn/manager/configuration/ConfigurationManager.java
@@ -536,6 +536,29 @@ public class ConfigurationManager extends BaseManager {
}
/**
+ * Lists the file names to which the given server is subscribed by channel
+ * Finds the deployable revisions for each file name.
+ * @param user The user requesting a list of file names
+ * @param server The server to which these files must be relevant
+ * @param channel The channel to which these files must be relevant
+ * @param pc A PageControl for this user
+ * @return A list of config file names in DTO format.
+ */
+ public DataResult <ConfigFileNameDto> listFileNamesForSystemChannel(User user,
+ Server server, ConfigChannel channel, PageControl pc) {
+ SelectMode m = ModeFactory.getMode("config_queries",
+ "file_names_for_system_channel");
+ Map params = new HashMap();
+ params.put("user_id", user.getId());
+ params.put("sid", server.getId());
+ params.put("ccid", channel.getId());
+ Map elabParams = new HashMap();
+ elabParams.put("sid", server.getId());
+ DataResult dr = makeDataResult(params, elabParams, pc, m);
+ return dr;
+ }
+
+ /**
* Lists the config channels in the user's config channel set to which the
* given server is subscribed. Finds the deployable files for each channel.
* @param user The user requesting a list of config channels
@@ -2041,13 +2064,38 @@ public class ConfigurationManager extends BaseManager {
public void deployConfiguration(User user,
Collection <Server> servers,
Date datePicked) {
+ deployConfiguration(user, servers, null, datePicked);
+ }
+
+
+ /**
+ * Schedules deploys of all the configuration files or dirs
+ * associated to a list of servers
+ *
+ * @param user User needed for authentication purposes..
+ * @param servers The list of servers, to whom the deploy action
+ * needs to be scheduled
+ * @param channel ConfigChannel to deploy files from
+ * @param datePicked date to deploy or null for the earliest date
+ */
+ public void deployConfiguration(User user,
+ Collection <Server> servers,
+ ConfigChannel channel,
+ Date datePicked) {
if (datePicked == null) {
datePicked = new Date();
}
for (Server server : servers) {
ensureConfigManageable(server);
- List <ConfigFileNameDto> names = listFileNamesForSystem(user,
- server, null);
+
+ List <ConfigFileNameDto> names;
+ if (channel == null) {
+ names = listFileNamesForSystem(user, server, null);
+ }
+ else {
+ names = listFileNamesForSystemChannel(user, server, channel, null);
+ }
+
Set <Server> system = new HashSet<Server>();
system.add(server);
Set <Long> revs = new HashSet<Long>();
12 years, 3 months
web/modules
by Jan Pazdziora
web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
New commits:
commit b224099589e62ca6bcdca268eff861e8335ec409
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Mar 21 10:31:13 2012 +0100
Fixing regular_systems_in_channel_family for PostgreSQL.
Addressing
RHN::Exception: DBD::Pg::st execute failed: ERROR: for SELECT DISTINCT, ORDER BY expressions must appear in select list at character 370
at /network/systems/system_list/regular_in_channel_family.pxt?cfam_id=1000
diff --git a/web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml b/web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml
index b97bc31..ebf799d 100644
--- a/web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml
+++ b/web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml
@@ -903,6 +903,7 @@ ORDER BY UPPER(NVL(X.NAME, '(none)')), X.ID
<mode name="regular_systems_in_channel_family">
<query params="org_id, cfam_id, user_id">
+select * from (
SELECT distinct S.id, S.name
FROM rhnServer S,
rhnServerChannel SC,
@@ -913,7 +914,8 @@ SELECT distinct S.id, S.name
AND SC.is_fve = 'N'
AND CFM.channel_family_id = :cfam_id
AND EXISTS (SELECT 1 FROM rhnUserServerPerms USP WHERE USP.user_id = :user_id AND USP.server_id = S.id)
-ORDER BY UPPER(NVL(S.NAME, '(none)')), S.ID
+) X
+ORDER BY UPPER(NVL(X.NAME, '(none)')), X.ID
</query>
<elaborator name="system_overview" />
<elaborator name="entitlements"/>
12 years, 3 months
schema/spacewalk
by Jan Pazdziora
schema/spacewalk/spacewalk-schema-upgrade | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit ead3b49102685bf7be7305e641beb2c8e85f61c5
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Tue Mar 20 15:44:31 2012 +0100
Glob returns its input when file does not exist, filter it out.
diff --git a/schema/spacewalk/spacewalk-schema-upgrade b/schema/spacewalk/spacewalk-schema-upgrade
index 40a9c3e..693b34e 100755
--- a/schema/spacewalk/spacewalk-schema-upgrade
+++ b/schema/spacewalk/spacewalk-schema-upgrade
@@ -317,7 +317,7 @@ sub get_shortest_path {
}
sub match_overrides {
- return sort map {-e "$_.override" ? "$_.override" : $_} map { glob } @_;
+ return sort map {-e "$_.override" ? "$_.override" : $_} grep { -e $_ } map { glob } @_;
}
1;
12 years, 3 months
java/code
by StephenHerr
java/code/src/com/redhat/rhn/manager/ssm/SsmManager.java | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
New commits:
commit c689edbf4b384c63d8a1752aa48a409e8310c7e3
Author: Stephen Herr <sherr(a)redhat.com>
Date: Tue Mar 20 09:48:35 2012 -0400
checkstyle fixes
diff --git a/java/code/src/com/redhat/rhn/manager/ssm/SsmManager.java b/java/code/src/com/redhat/rhn/manager/ssm/SsmManager.java
index 611e07e..de6e3e5 100644
--- a/java/code/src/com/redhat/rhn/manager/ssm/SsmManager.java
+++ b/java/code/src/com/redhat/rhn/manager/ssm/SsmManager.java
@@ -20,7 +20,6 @@ import com.redhat.rhn.domain.channel.Channel;
import com.redhat.rhn.domain.rhnset.RhnSet;
import com.redhat.rhn.domain.rhnset.RhnSetElement;
import com.redhat.rhn.domain.server.Server;
-import com.redhat.rhn.domain.server.ServerFactory;
import com.redhat.rhn.domain.user.User;
import com.redhat.rhn.frontend.action.channel.ssm.ChannelActionDAO;
import com.redhat.rhn.manager.channel.ChannelManager;
@@ -99,9 +98,9 @@ public class SsmManager {
while (it.hasNext()) {
Channel channel = idToChan.get(it.next());
Long availableEntitlements = channelToAvailableEntitlements.get(channel);
- Long availableFteEntitlements =
+ Long availableFteEntitlements =
channelToAvailableFteEntitlements.get(channel);
-
+
if (availableEntitlements == null) {
availableEntitlements =
ChannelManager.getAvailableEntitlements(user.getOrg(), channel);
@@ -115,9 +114,10 @@ public class SsmManager {
if (availableFteEntitlements == null) {
availableFteEntitlements = 0L;
}
- channelToAvailableFteEntitlements.put(channel, availableFteEntitlements);
+ channelToAvailableFteEntitlements.put(
+ channel, availableFteEntitlements);
}
-
+
//Most likely a custom channel, null means unlimited entitlements
if (availableEntitlements == null) {
continue;
@@ -125,8 +125,8 @@ public class SsmManager {
// First try to consume an FTE entitlement, then try regular,
// then remove the system
- if (availableFteEntitlements > 0
- && SystemManager.isServerFveEligible(server)) {
+ if (availableFteEntitlements > 0 &&
+ SystemManager.isServerFveEligible(server)) {
availableFteEntitlements -= 1;
channelToAvailableEntitlements.put(channel, availableFteEntitlements);
}
12 years, 3 months
Changes to 'refs/tags/spacewalk-setup-1.7.10-1'
by Jan Pazdziora
Tag 'spacewalk-setup-1.7.10-1' created by Jan Pazdziora <jpazdziora(a)redhat.com> at 2012-03-20 13:45 +0000
Tagging package [spacewalk-setup] version [1.7.10-1] in directory [spacewalk/setup/].
Changes since spacewalk-java-1.7.54-1:
Jan Pazdziora (2):
Reverting removal of traceback_mail.
Automatic commit of package [spacewalk-setup] release [1.7.10-1].
---
rel-eng/packages/spacewalk-setup | 2 +-
spacewalk/config/var/lib/rhn/rhn-satellite-prep/etc/rhn/rhn.conf | 1 +
spacewalk/setup/spacewalk-setup.spec | 5 ++++-
3 files changed, 6 insertions(+), 2 deletions(-)
---
12 years, 3 months