The following are 2 corresponding sets of config statements. The first one is for Nginx and the second one for Apache2 servers.
The Ubuntu Apache2 config code is modelled after the Nginx code to provide the same functionality.
The two config paragraphs work the same except that the Nginx code paragraph has an extra "set $args" statement.
# Nginx Sample
server {
listen 80;
server_name AAA.com www.AAA.com;
location /Test_Path {
set $args "$args&jscode=123456”;
proxy_pass http://www.BBB.com/;
}
}
# # # # # # # # # # # # # # # # # # # # # # # #
# Apache2 Sample
<VirtualHost *:80>
ServerName AAA.com
ServerAlias www.AAA.com
ProxyPass /Test_Path http://www.BBB.com/
ProxyPassReverse /Test_Path http://www.BBB.com/
</VirtualHost>
My question is :
How to add Apache2 config statement (or statements) which can function as the extra Nginx statement.
The extra Nginx statement is used to pass a private key string to a backend server from its reverse proxy. The statement is singled out and displayed below :
set $args "$args&jscode=123456”;
Background info of this question :
The Nginx config code was adopted from sample code from a service provider. I do not have any Nginx server to test it. But the code should work because it is from an established provider.
The Apache2 trial code was adapted from various sample code from the internet.
I have tested the Apache2 trial code quite thoroughly and it seems to work as expected.
The only thing left out of the Apache2 config trial code is the "set $args" statement.
The "set $args" statement is used to pass a private key to a backend server.
The service provider's technical support people say they only have sample config code for Nginx servers. They also say they are not familiar with Apache.
But the same support people also say Apache servers should work if they have reverse proxy capability.
I am new to web servers setup. But I have spent quite some time researching before coming up with this simplified trial code for testing on an Apache2 server.
If you have any insight into this please share some of your valuable advice and suggestions.
Any comments, advice or suggestions are appreciated. Looking forward to hear from you.