So here are the task that I have tried to set the WSO2 API manager and the Micro Gateway services in my local system , so here is a sample configuration
OS: Ubuntu server 18 LTS
WSO2 API Manager - Local Server IP: 192.168.1.50
WSO2 MicroGateway service (Sandbox) - Local Server IP: 192.168.1.51
WSO2 MicroGateway service (Production) - Local Server IP: 192.168.1.52
API Manager:
- Installed all prerequisites
- Install directly in the server
- Changed the hostname to IP address in deployment.toml since I tried changing in carbon.xml and api-manager.xml but it get override
- All the services were successfully active
- Carbon Admin - http://192.168.1.50:9443/carbon, Admin Module - http://192.168.1.50:9443/admin, Developer Portal - http://192.168.1.50:9444/devportal, Publisher - http://192.168.1.50:9443/publisher
MicroGateway:
- Create a mock hello world API using PHP to access the backend and datastore services.
- Created a sample OpenAPI 3.0 yaml file to forward the request to the backend php services.
- Installed all prerequisites
- I had document to install the Microgateway services in docker, but I decided to try the MGW services installation directly within the server without docker
- Created a API using micro-gw init and placed the yaml file within api-definitions
- created the build successfully
- Ran the build using gateway which was accessible using Postman.
- Tried to change the hostname of microgateway service to listen IP instead of localhost but gets overrides to localhost:9090 however the service can be accessible using IP so no further changes made.
Configuration of API Manager and MGW
- Uploaded the same YAML to API manager using publisher to configure the API manager and microgateway services.
- Used API managers key certificates to set the microgateway (which failed)
- create the end points to point to Production and Sandbox micro gateways using the IP address and the port number http://192.168.1.51:9090 and http://192.168.1.52:9090
- Accessed the developer portal, created a token key.
- However, the token failed to help access the microgateway service. Even I tried using the URL provided by the API manager http://192.168.1.50/sample/context/1/test but still inaccessible.
The Configuration was unsuccessful