Search code examples
knox-gateway

how to integrate custom services into apache knox 0.9.1


I got a need to integrate various service webUIs into knox gateway.For now ,i use CAS as authentication and got hdfs,hbaseUI,sparkHistoryUI worked fine.I searched google and baidu and found no detailed materials or docs for knox rewrite.xml,so i got problems in integrating new services such as kibana,hue etc.The root cause is that rewrite.xml contains many tags and attr that i just know nothing about. As a try,i integrate tomcat7.0 ROOT webapp.here is the correspond service.xml and rewrite.xml:

service.xml

rewrite.xml

when i connect the tomcat home page ,everything is ok.but when i clicked the hyper-link "configuration" in the navigation bar. i got infinite number of redirect and finally "ERR_TOO_MANY_REDIRECTS" in the browser. My question is :1)how to write the rewrite.xml to make this demo work fine. 2)is there any materials or documents about the detail of rewrite tags to share I will appreciate if any one would help.thanks!


Solution

  • Start with this article: https://cwiki.apache.org/confluence/display/KNOX/Proxying+a+UI+using+Knox

    For additional information, you can also see the documentation for service definition files: http://knox.apache.org/books/knox-0-9-1/dev-guide.html#Service+Definition+Files

    Hope this is helpful.