apisix icon indicating copy to clipboard operation
apisix copied to clipboard

request help: How the nginx configured Location smoothly migrates to apisix

Open Infra-YH opened this issue 5 years ago • 8 comments

image

How to use the functions above the apisix proxy is as effective as the Nginx configuration and can be accessed normally

Infra-YH avatar Jan 11 '21 13:01 Infra-YH

At present, the front end is through the domain name matching path / , but / apisix / admin this kind of match should do, it is best to have some examples

Infra-YH avatar Jan 11 '21 13:01 Infra-YH

@Yangzcy423911 you can provide the fake nginx configuration text directly, it easy to discuss.

membphis avatar Jan 11 '21 13:01 membphis

nginx config:

log_format  apigateway  '$remote_addr - $remote_user [$time_local] "$request" $status $body_bytes_sent "$http_referer" "$http_user_agent" "$http_x_forwarded_for" "$request_time" "$upstream_response_time"';
#access_log  logs/wechat.log  ;
#error_log  logs/wechaterror.log  info;
server {
        listen       81;
        server_name  192.168.1.100;
        root /opt/front/uat-gateway/html;
        access_log  logs/uat-apigateway.log apigateway;
      location ^~ / {
                 try_files $uri $uri/ /index.html;
        }
      location /apisix/admin {
                 proxy_pass http://192.168.1.100:1001/apisix/admin;
        }
}

Thanks I

Infra-YH avatar Jan 11 '21 13:01 Infra-YH

how to use apisix router about full router

Infra-YH avatar Jan 11 '21 13:01 Infra-YH

@Yangzcy423911 you can put your original route rule, then we can help you to check where is wrong

membphis avatar Jan 12 '21 09:01 membphis

original route rule please visit https://github.com/apache/apisix/issues/3252 detail

Infra-YH avatar Jan 12 '21 09:01 Infra-YH

This issue has been marked as stale due to 350 days of inactivity. It will be closed in 2 weeks if no further activity occurs. If this issue is still relevant, please simply write any comment. Even if closed, you can still revive the issue at any time or discuss it on the [email protected] list. Thank you for your contributions.

github-actions[bot] avatar Dec 28 '21 10:12 github-actions[bot]

This issue has been closed due to lack of activity. If you think that is incorrect, or the issue requires additional review, you can revive the issue at any time.

github-actions[bot] avatar Jan 11 '22 10:01 github-actions[bot]