0

The request coming to the server at port 5082 as below

GET /iFooBar?mode=update&av=V12-00-068_466533&rv=0&sv=0&os=Linux&os_arch=aarch64&os_ver=4.15.0-1031-raspi2 HTTP/1.0

i want to pass it to the revers proxy to be same as below:

GET /iFooBar?mode=update&av=V12-00-068_466533&rv=180144&sv=0&os=Linux&os_arch=amd64&os_ver=4.9.0-9-amd64 HTTP/1.1

The parameters:

rv=0 should be passed as rv=180144

os_arch=aarch64 should be passed as os_arch=amd64

os_ver=4.15.0-1031-raspi2 should be passed as os_ver=4.9.0-9-amd64

My configuration:

server {
    listen 5082;
    listen [::]:5082;
    server_name mytest.server.com;
    location / {
      #rewrite    ^(.*)aarch64(.*)$    $amd64$2; #// Not working
      proxy_pass http://10.10.10.10:5080;
      proxy_set_header   Connection keep-alive;
      proxy_read_timeout  1200s;
      client_max_body_size 0;
    }
}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.