Browse Source

AMBARI-2533. WebHcat tests fail since the proxy group and hosts is not set for HTTP principle. (jaimin)

git-svn-id: https://svn.apache.org/repos/asf/incubator/ambari/trunk@1498742 13f79535-47bb-0310-9956-ffa450edef68
Jaimin Jetly 12 years ago
parent
commit
26d853e121

+ 9 - 0
ambari-web/app/controllers/main/admin/security/add/step3.js

@@ -356,6 +356,15 @@ App.MainAdminSecurityAddStep3Controller = Em.Controller.extend({
         value: hiveHostName
         value: hiveHostName
       });
       });
     }
     }
+    var webHcatComponent =  App.Service.find('WEBHCAT').get('hostComponents').findProperty('componentName', 'WEBHCAT_SERVER');
+    if(this.isWebHcatSelected() && webHcatComponent) {
+     var webHcatHostName =  webHcatComponent.get('host.hostName');
+      this.get('globalProperties').pushObject({
+        id: 'puppet var',
+        name: 'webhcat_server',
+        value: webHcatHostName
+      });
+    }
   },
   },
 
 
   loadStaticGlobal: function () {
   loadStaticGlobal: function () {

+ 16 - 0
ambari-web/app/data/secure_mapping.js

@@ -457,6 +457,22 @@ module.exports = [
     "value": "<templateName[0]>",
     "value": "<templateName[0]>",
     "filename": "core-site.xml",
     "filename": "core-site.xml",
     "serviceName": "OOZIE"
     "serviceName": "OOZIE"
+  },
+  {
+    "name": "hadoop.proxyuser.<foreignKey[0]>.groups",
+    "templateName": ["proxyuser_group"],
+    "foreignKey": ["webHCat_http_primary_name"],
+    "value": "<templateName[0]>",
+    "filename": "core-site.xml",
+    "serviceName": "WEBHCAT"
+  },
+  {
+    "name": "hadoop.proxyuser.<foreignKey[0]>.hosts",
+    "templateName": ["webhcat_server"],
+    "foreignKey": ["webHCat_http_primary_name"],
+    "value": "<templateName[0]>",
+    "filename": "core-site.xml",
+    "serviceName": "WEBHCAT"
   }
   }
 ];
 ];