Ottomata has submitted this change and it was merged.

Change subject: Adding role::analytics::hue
......................................................................


Adding role::analytics::hue

Change-Id: Id912094dd09de5c27185fc3b1437131f8e12e7bd
---
A manifests/role/analytics/hue.pp
1 file changed, 39 insertions(+), 0 deletions(-)

Approvals:
  Ottomata: Verified; Looks good to me, approved
  jenkins-bot: Verified



diff --git a/manifests/role/analytics/hue.pp b/manifests/role/analytics/hue.pp
new file mode 100644
index 0000000..bcdb260
--- /dev/null
+++ b/manifests/role/analytics/hue.pp
@@ -0,0 +1,39 @@
+# == Class role::analytics::hue
+# Installs Hue server.
+#
+class role::analytics::hue {
+    # I have to require/include the oozie and hive roles
+    # manually here.  I'd rather just make them dependencies
+    # of this class, but for some reason, they are not evaluated
+    # properly (at least in labs) before cdh4::hue gets evalutated,
+    # which causes $cdh4::oozie::url to be undefined.
+    require role::analytics::hive::client
+    require role::analytics::oozie::client
+
+    include ldap::role::config::labs
+
+    if ($::realm == 'production') {
+        include passwords::analytics
+        $secret_key         = $passwords::analytics::hue_secret_key
+    }
+    elsif ($::realm == 'labs') {
+        $secret_key         = 
'oVEAAG5dp02MAuIScIetX3NZlmBkhOpagK92wY0GhBbq6ooc0B3rosmcxDg2fJBM'
+    }
+
+    class { '::cdh4::hue':
+        secret_key             => $secret_key,
+        smtp_host              => 'mchenry.wikimedia.org',
+        smtp_from_email        => "hue@$::fqdn",
+        ldap_url               => inline_template('<%= 
scope.lookupvar("ldap::role::config::labs::servernames").collect { |host| 
"ldaps://#{host}" }.join(" ") %>'),
+        ldap_bind_dn           => 
$ldap::role::config::labs::ldapconfig['proxyagent'],
+        ldap_bind_password     => 
$ldap::role::config::labs::ldapconfig['proxypass'],
+        ldap_base_dn           => $ldap::role::config::labs::basedn,
+        ldap_username_pattern  => 
'uid=<username>,ou=people,dc=wikimedia,dc=org',
+        ldap_user_filter       => 'objectclass=person',
+        ldap_user_name_attr    => 'uid',
+        ldap_group_filter      => 'objectclass=posixgroup',
+        ldap_group_member_attr => 'member',
+    }
+}
+
+# TODO: Hue SQLite database backup.

-- 
To view, visit https://gerrit.wikimedia.org/r/74388
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id912094dd09de5c27185fc3b1437131f8e12e7bd
Gerrit-PatchSet: 7
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ottomata <[email protected]>
Gerrit-Reviewer: Ottomata <[email protected]>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to