Spyke

Posts

On Ukraine, Biden needs to listen to these US generals

President Biden’s support for the Ukrainian war effort continues to be just enough for Ukraine to survive, but not enough for it to win. For Ukraine, this is like treading water wearing a 25 lb. life preserver. All your energy is required just to stay afloat; nothing is left to swim ashore.

When will the president start listening to his generals — his own military advisers? One can only assume the advice he is acting on is coming from the likes of national security advisor Jake Sullivan, Secretary of State Anthony Blinken or former U.S. Ambassador to the United Nations Susan Rice.

On Ukraine, Biden needs to listen to these US generalshttps://thehill.com/opinion/national-security/4178980-on-ukraine-biden-needs-to-listen-to-these-us-generals/Open linkView original on sopuli.xyz
40
selfhosted·SelfhostedbySpaceCadet

nginx reverse proxy using subpaths help

So I have a webserver running nginx, and I want to use it as a reverse proxy to access web applications running elsewhere. I know this is a pretty standard use case, and that the traditional approach is to use virtual hosts to proxy the different apps.

Like, normally you would do something like:

I am familiar with this approach, and know how to set it up.

In this case, there is a catch though. For reasons that I can't get into here, I can't use virtual hosts, and everything should be hosted in the same webserver.something domain. So I thought I would use a subpath to host each app.

What I want to do is this basically:

In my nginx config file I have something like this:

upstream app1 {
  server app1.host:3000;
}

server {
    ...
    location /app1 {
        proxy_pass http://app1/;
    }
    ...
}

This works to the extent that all requests going to /app1/* get forwarded to the correct application host. The issue though is that the application itself uses absolute paths to reference some resources. For example, app1 will try to reference a resource like /_app/something/something.js, which of course produces a 404 error.

I suppose that for this particular error I could map /_app/ to the app1 application host with another location statement, but that seems dirty to me and I don't like it. First off it could quickly become a game of whack-a-mole, trying to get all the absolute paths remapped, and secondly it could easily lead to conflicts if other applications use that absolute path too.

So I guess my question is: is there a way to do this cleanly, and dynamically rewrite those absolute paths per app?

View original on sopuli.xyz
18
alexandrite·AlexandritebySpaceCadet

[META] Preferred way to request features?

Question for @[email protected]:

What's your preferred way to receive feature requests?

I see people making posts here, which is nice because it allows community discussion, but you also have a github issue tracker, which may be handier for you to actually follow up the request. I have some ideas I'd like to put forward, and I would like to use the way that's the least burdensome for you to manage.

View original on sopuli.xyz
4

You reached the end