snips.sh behind an Ingress on K8s #48
Replies: 2 comments
-
👋 Thanks for using snips! Generally I'm not a huge fan of path-based ingress routing � , would very much prefer a host-based or subdomain as an alternative. I threw together a quick edit of what it would be like to enable path based routing: https://github.com/robherley/snips.sh/compare/robherley/external-path-routing using: ![]() Feel free to pull that branch and try it out! If I were to add this fully, I'd definitely want a more batteries-included router like chi and would need some actual tests for the http server. There's a lot of corner cases around routes when it comes to signing the URL for private snippets, so having tests in place would give a lot more confidence. I should have time to implement this soon 👍 |
Beta Was this translation helpful? Give feedback.
-
Hi Rob! Thank you very much! I asked about this, because I'm writing (for fun) a Charmed Operator for snips, and the Ingress I'll use provides the alternative to use path-ingress routing. I'll give it a try, and let you know. Cheers |
Beta Was this translation helpful? Give feedback.
-
Hello,
I would like to run snips.sh on K8s. For that I will use an ingress that provides an URL like this one for the snips.sh instance:
http://192.168.122.10/snips-snips-0/
When I use that url in the env var
SNIPS_HTTP_EXTERNAL
, snips removes thepath
provided by the ingress (in this case:snips-snips-0
)For instance:
the url generated is
http://192.168.122.10:80/f/gvi4MTObj0
and should behttp://192.168.122.10:80/snips-snips-0/f/gvi4MTObj0
Is there a way to avoid snips.sh remove the
path
?Beta Was this translation helpful? Give feedback.
All reactions