server { listen 80; location / { proxy_pass http://public-pool_web_1:80; } location ~* ^/api/ { proxy_pass http://public-pool_server_1:2019; } }