1
votes

I'm using WSO2 API Manager for creating and managing a developer community. According to my knowledge API manager is driven on WSO2 Carbon Server which again runs on Apache Tomcat.

Up to now I'm able to run WSO2 API manager without any issues. I could open up store and publisher using below urls.

https://<MyHostName>:9443/publisher
https://<MyHostName>:9443/store

What I want to know is, how can I expose these two URLs to public? I would like something like below as URLs(without ports).

https://<MyHostName>/publisher
https://<MyHostName>/store

or

https://publisher.<MyHostName>
https://store.<MyHostName>

Given that for URLs without https(just http) would be great if possible.

In WSO2 API Manager, How can I expose Publisher & Store URLs to public?

1
I feel like it would be much cleaner if you front an nginx and proxy pass the request to the required urldushansilva

1 Answers

3
votes

You can do this by editing catalina-server.xml file located in <APIM>/repository/conf/tomcat folder. Change the port and redirectPort values specified in NIO Connectors.

<Connector  protocol="org.apache.coyote.http11.Http11NioProtocol"
                port="80"
                redirectPort="443" 
                bindOnInit="false"
                maxHttpHeaderSize="8192"
                acceptorThreadCount="2"
                maxThreads="250"
                minSpareThreads="50"
                disableUploadTimeout="false"
                connectionUploadTimeout="120000"
                maxKeepAliveRequests="200"
                acceptCount="200"
                server="WSO2 Carbon Server"
                compression="on"
                compressionMinSize="2048"
                noCompressionUserAgents="gozilla, traviata"
                compressableMimeType="text/html,text/javascript,application/x-javascript,application/javascript,application/xml,text/css,application/xslt+xml,text/xsl,image/gif,image/jpg,image/jpeg" 
                URIEncoding="UTF-8"/>

    <Connector  protocol="org.apache.coyote.http11.Http11NioProtocol"
                port="443"
                bindOnInit="false"
                sslProtocol="TLS"
                maxHttpHeaderSize="8192"
                acceptorThreadCount="2"
                maxThreads="250"
                minSpareThreads="50"
                disableUploadTimeout="false"
                enableLookups="false"
                connectionUploadTimeout="120000"
                maxKeepAliveRequests="200"
                acceptCount="200"
                server="WSO2 Carbon Server"
                clientAuth="false"
                compression="on"
                scheme="https"
                secure="true"
                SSLEnabled="true"
                compressionMinSize="2048"
                noCompressionUserAgents="gozilla, traviata"
                compressableMimeType="text/html,text/javascript,application/x-javascript,application/javascript,application/xml,text/css,application/xslt+xml,text/xsl,image/gif,image/jpg,image/jpeg"
                URIEncoding="UTF-8"/>