Skip to content

Commit

Permalink
Fixes #19630: more server role/component cleaning
Browse files Browse the repository at this point in the history
  • Loading branch information
fanf authored and Jenkins CI committed Jul 30, 2021
1 parent 22c867b commit 41764fd
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 25 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -130,24 +130,6 @@ description: All nodes known by Rudder (excluding Rudder policy servers)
isEnabled: TRUE
isSystem: TRUE

dn: ruleTarget=special:all_servers_with_role,groupCategoryId=SystemGroups,groupCategoryId=GroupRoot,ou=Rudder,cn=rudder-configuration
objectClass: specialRuleTarget
objectClass: top
ruleTarget: special:all_servers_with_role
cn: All nodes with a Server role
description: All nodes that have at least one Server role defined
isEnabled: TRUE
isSystem: TRUE

dn: ruleTarget=special:all_nodes_without_role,groupCategoryId=SystemGroups,groupCategoryId=GroupRoot,ou=Rudder,cn=rudder-configuration
objectClass: specialRuleTarget
objectClass: top
ruleTarget: special:all_nodes_without_role
cn: All nodes excluding Rudder server roles
description: All nodes excluding Rudder server components
isEnabled: TRUE
isSystem: TRUE

dn: nodeGroupId=all-nodes-with-cfengine-agent,groupCategoryId=SystemGroups,groupCategoryId=GroupRoot,ou=Rudder,cn=rudder-configuration
objectClass: nodeGroup
objectClass: top
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,6 @@ object QSDirectiveBackend extends Loggable {
case Properties => None
case CustomProperties => None
case NodeState => None
case RudderRoles => None
case GroupId => None
case IsDynamic => None
case ParameterName => None
Expand Down Expand Up @@ -388,7 +387,6 @@ object QSLdapBackend {
case Properties => sub(a, token)
case CustomProperties => sub(a, token)
case NodeState => sub(a, token)
case RudderRoles => sub(a, token)
case GroupId => sub(a, token)
case IsEnabled => bool(MatchEnable, a, token)
case IsDynamic => bool(MatchDynamic, a, token)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,6 @@ object QSAttribute {
}
final case object Properties extends QSAttribute { override val name = "properties" }
final case object CustomProperties extends QSAttribute { override val name = "properties" }
final case object RudderRoles extends QSAttribute { override val name = "rudder_roles"}

//Groups
final case object GroupId extends QSAttribute {
Expand Down Expand Up @@ -217,7 +216,7 @@ object QSObject {
final case object Node extends QSObject { override val name = "node"
override val attributes : Set[QSAttribute] = Common.attributes ++ Set(NodeId, Fqdn, OsType, OsName
, OsVersion, OsFullName, OsKernelVersion, OsServicePack, Arch, Ram
, IpAddresses, PolicyServerId, Properties, CustomProperties, RudderRoles, NodeState)
, IpAddresses, PolicyServerId, Properties, CustomProperties, NodeState)
}
final case object Group extends QSObject { override val name = "group"
override val attributes : Set[QSAttribute] = Common.attributes ++ Set(GroupId, IsDynamic)
Expand Down Expand Up @@ -295,7 +294,6 @@ final object QSMapping {
case Properties => (a, Set(Properties.name, "node.props", "nodeprops", "node_properties", "nodeproperties") )
case CustomProperties => (a, Set(CustomProperties.name, "node.props", "nodeprops", "node_properties", "nodeproperties") )
case NodeState => (a, Set(NodeState.name, "nodestate"))
case RudderRoles => (a, Set(RudderRoles.name, "serverrole", "serverroles", "role", "roles") )
case GroupId => (a, Set(GroupId.name, "groupid", "group_id") )
case IsDynamic => (a, Set(IsDynamic.name) )
case DirectiveId => (a, Set(DirectiveId.name, "directiveid", "directive_id") )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ class TestQueryProcessor extends Loggable {
res.size
}).runNow

val expected = 43+38 //bootstrap + inventory-sample
val expected = 41+38 //bootstrap + inventory-sample
assert(expected == s, s"Not found the expected number of entries in test LDAP directory [expected: ${expected}, found: ${s}], perhaps the demo entries where not correctly loaded")
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<span class="ion ion-checkmark-round check-icon"></span>
</label>
<label for="typeQuery" class="form-control">
Include Rudder root server components <span class="icon-info tooltipable glyphicon glyphicon-question-sign" title="Node(s) with Rudder web application or Rudder database"></span>
Include Rudder root <span class="icon-info tooltipable glyphicon glyphicon-question-sign" title="The Rudder root server with web application"></span>
</label>
</div>
</li>
Expand Down

0 comments on commit 41764fd

Please sign in to comment.