What to add for context paths

If your application uses context paths, then you will need to provide us a list of the context paths. This is so that we can map the Domain to the APIs we find in your codebase.

Webserver

If you are using a webserver to add context paths (Nginx / HAProxy / Traefik / Istio) you will have a configuration file that you can download and paste below.

Nginx
  1. /etc/nginx/nginx.conf

  2. /etc/nginx/sites-available/default

  3. /etc/nginx/sites-available

Specifically we care about anything that looks like the following:

server { location /contextPath/ { proxy_pass http://backendserver/url/; } }

server { location /contextPath/ { proxy_pass http://backendserver/url/; } }

server { location /contextPath/ { proxy_pass http://backendserver/url/; } }

Apache HTTP Server

Configuration Files:

  1. /etc/httpd/conf/httpd.conf

  2. Any .conf in /etc/httpd/conf.d

Example:

Alias /contextPath /path/to/resource ProxyPass /contextPath http://backendserver/url/ ProxyPassReverse /contextPath http://backendserver/url/

Alias /contextPath /path/to/resource ProxyPass /contextPath http://backendserver/url/ ProxyPassReverse /contextPath http://backendserver/url/

Alias /contextPath /path/to/resource ProxyPass /contextPath http://backendserver/url/ ProxyPassReverse /contextPath http://backendserver/url/

Tomcat

Configuration Files:

  1. /conf/server.xml or any .xml places in conf/Catalina/localhost for each application

Example:

<Context path="/contextPath" docBase="/path/to/application" />

<Context path="/contextPath" docBase="/path/to/application" />

<Context path="/contextPath" docBase="/path/to/application" />

Jetty

Configuration Files:

  1. This can be a wide variety of configuration files (there is no single place for Jetty to define this). Look for xml configuration files.

Example:

<web-app> <context-param> <param-name>contextPath</param-name> <param-value>/yourContextPath</param-value> </context-param> </web-app>

<web-app> <context-param> <param-name>contextPath</param-name> <param-value>/yourContextPath</param-value> </context-param> </web-app>

<web-app> <context-param> <param-name>contextPath</param-name> <param-value>/yourContextPath</param-value> </context-param> </web-app>

HAProxy

Configuration Files:

  1. Typically found at /etc/haproxy/haproxy.cfg

Example:

frontend http_front bind *:80 acl url_app1 path_beg /app1 acl url_app2 path_beg /app2 use_backend app1_backend if url_app1 use_backend app2_backend if url_app2 backend app1_backend server app1_1 app1.example.com:80 backend app2_backend server app2_1 app2.example.com:80

frontend http_front bind *:80 acl url_app1 path_beg /app1 acl url_app2 path_beg /app2 use_backend app1_backend if url_app1 use_backend app2_backend if url_app2 backend app1_backend server app1_1 app1.example.com:80 backend app2_backend server app2_1 app2.example.com:80

frontend http_front bind *:80 acl url_app1 path_beg /app1 acl url_app2 path_beg /app2 use_backend app1_backend if url_app1 use_backend app2_backend if url_app2 backend app1_backend server app1_1 app1.example.com:80 backend app2_backend server app2_1 app2.example.com:80

Cloud Service

If you are using a cloud service to add context paths (AWS ALB, Azure Application Gateway, AWS API Gateway etc), you will have to go their respective configurations and pull out the context paths.

  1. AWS API Gateway

  2. Azure Application Gateway

  3. Azure Front Door

Contact us

If you are facing any trouble setting up your on-prem application, reach out to us at contact[at]p0[dot]inc

Contact us

If you are facing any trouble setting up your on-prem application, reach out to us at contact[at]p0[dot]inc

Contact us

If you are facing any trouble setting up your on-prem application, reach out to us at contact[at]p0[dot]inc

© 2024 p

0

. All rights reserved.

© 2024 p

0

. All rights reserved.

© 2024 p

0

. All rights reserved.