we have 3 static sites along with one API server we want to enable API metering and rate-limiting and dynamic routing.
I have tested this thing with kong and API server its working Great.
I have to thoughts official documentation to host static content on kong they ask to create location section for the single site but that does not fulfill my requirement.
I like to know more about how to setup 3 static sites with the single API service. can anyone guide me on this?
So you want to host the sites on the nginx web server Kong is currently running on? I suppose a custom kong template change could do it.
Basically you will need to make server blocks/ports or locations pointing to the static content you desire to serve. How those sites will interact with your Kong API proxy is up to you
User -> Hits path on port :9393(some random port you decide to use with new server block, or make new locations within a server block) -> server block serves static content from a location you drop the files and point nginx to, user takes action on some landing page -> calls kong proxy on location “/” port 8000/8443 -> Auth/rate limiting/whatever can happen against those APIs. Is this
kinda what you are talking about? I personally would rather have two separate web servers, one running the site and one running the gateway just for simplicity sake(do one thing well motto).