cloudflare / pingora

A library for building fast, reliable and evolvable network services.
Apache License 2.0
20.64k stars 1.12k forks source link

need more examples or docs just like some nginx cases build with pingora #56

Closed dayuoba closed 3 months ago

dayuoba commented 5 months ago

i want to trans some nginx case to pingora like:

server {
    listen 80;
    server_name example.com;
    location /serviceA/ {
        max_body_size 100m;
        proxy_pass http://serviceA.example.com/; 
    }

    location /serviceB/ {
        max_body_size 20m;
        proxy_pass http://serviceB.example.com/;
    }
}

i need more documents to help me do this the best practice way

mustafasegf commented 4 months ago

there's an example for that already https://github.com/cloudflare/pingora/blob/main/docs/user_guide/modify_filter.md

gdavidsson commented 4 months ago

Hi folks! Thanks @mustafasegf -- yeah, seems that the Routing + Return Error pages examples covers how you can proxy_pass and send error responses based on certain conditions of the request. @dayuoba do you have any remaining question here?

drcaramelsyrup commented 3 months ago

Closing this as answered.