acouvreur / sablier

Start your containers on demand, shut them down automatically when there's no activity. Docker, Docker Swarm Mode and Kubernetes compatible.
https://acouvreur.github.io/sablier/
GNU Affero General Public License v3.0
1.27k stars 46 forks source link

Feature Request: Change strategy based on endpoint #376

Closed Glich440 closed 22 hours ago

Glich440 commented 3 weeks ago

Is there a way for all requests to use the dynamic strategy except if they're going to the /api endpoint?

acouvreur commented 3 weeks ago

You should be able to create two different routes using your reverse proxy. Then define the proper middleware on each route.

The Sablier middleware does not make decision based on the route or anything else.

If your this cannot be solved using two routes, please explain your setup in detail as why you cannot do that.

Thanks! 😀

Glich440 commented 22 hours ago

after actually using sablier I realized how to actually do that, thanks for the help!