problems with wp and reverse proxy

  • [Geändert - Ich weiß gar nicht warum ich das eigentlich auf engl. gepostet habe hier die deutsche Version:]

    German (for english see below)
    Hallo alle zusammen,

    erst einmal Danke dass Ihr so lieb seid mein Problem anzuschauen.

    Ich betreibe einen WP Blog auf einem dedicated server. dieser wird von unserem load balancer (nginx) per proxy_pass aufgerufen. Mein Problem ist dass ich gerne allen Statischen Content direkt vom NginX ausliefern lassen möchte. Nicht aber den Content vom Blog, da dieser sich ja ständig ändert. Wie kann ich bloß dem NGINX sagen dass er zwar alle statischen Dateien ausliefern muss aber nicht wenn der blog aufgerufen wurde ("/blog/" in der URL) Unten meine NGINX Config.


    English:
    Hello all,

    first of all thanks for looking into this. I have the following problem.

    Wordpress is running on a dedicated server only for wordpress out application is running on other application servers. to handle the load we have also a load balancer working. To deliver the load as fast as possible we deliver static content directly via the lb (nginx). Here my question:

    1) the load balancer gets the request
    2a) if its static conent is delivers it directly
    2b) if its application relevant it forwards the request to the tomcats on the application servers
    2c) if its blog content (location /blog) nginx get the blog information via proxy pass from the dedicated blog server.

    My Problem is now that in case of 2c) i dont want to deliver the static content from the load balancer directly (because its not there).. for all /blog/ content nginx should get ALL data via proxy_pass from wordpress..

    Any ideas?

    here is my current server configuration for nginx (that is not working for /blog/ :) :

    Einmal editiert, zuletzt von twago (12. Juli 2010 um 14:17)

    • Anzeige

    Hallo!

    Wenn du gerade an deiner Website arbeitest oder dein aktuelles Hosting überdenkst: Wir betreiben mit NetzLiving eine Hosting-Plattform, die speziell auf Performance, Sicherheit und einfache Verwaltung ausgelegt ist.

    • ✔️ Schnelle Ladezeiten (optimiert für WordPress & Co.)
    • ✔️ Deutsche Server & DSGVO-konform
    • ✔️ Persönlicher Support (kein 0815-Ticket-System)

    Mehr erfahren

  • Schau mal auf Deine Hooks. Vielleicht ladest Du zu spät, zu früh oder so.. Da gibt's im Codex eine Hook-Datenbank. Vielleicht bei "init" schon eine weiche machen.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!