Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]
Created 06-21-2016 09:31 PM
I am trying to modify the template of the alert notification. I see in the template code it tries to display ambari url but it never displays that. The lower end of the template reads like
<div class="ambari-footer">
This notification was sent to $dispatch.getTargetName()
<br/>
Apache Ambari $ambari.getServerVersion()
#if( $ambari.hasUrl() )
<br/>
Ambari Server link: <a href=$ambari.getUrl()>$ambari.getUrl()</a>
#end
</div>
</html>
]]>
</body>But I think method
ambari.hasUrl()
is always false. I tried printing the
$ambari.getUrl()
but it displays as it is. In the emails I see "$ambari.getUrl()". I checked the code
@Inject private Configuration m_configuration;
I am not sure from where it is getting injected from. Any suggestions why ambari url is not coming in the configs.
Created 06-21-2016 10:19 PM
It needs to take a static value from the /etc/ambari-server/conf/ambari.properties file. You need to add this and restart:
ambari.display.url = http://www.myserver.com
Created 06-21-2016 10:19 PM
It needs to take a static value from the /etc/ambari-server/conf/ambari.properties file. You need to add this and restart:
ambari.display.url = http://www.myserver.com
Created 06-21-2016 11:08 PM
I added
ambari.display.url = http://100.123.123.123:8080 in properties file
but I still dont see ambari url in the email. I manually added
$ambari.getUrl() but it gets in the email as it is. Any other thing that I can do?
Created 06-22-2016 02:11 AM
Got it. Tried it on a different cluster and this is working