create-proxy

Adds a per-directory proxy to some domain A proxy maps some URL on a virtual server to another webserver. This means that requests for any page under that URL path will be forwarded to the other site, which could be a separate machine or another webserver process on the same system. The --domain parameter must be given and followed by a virtual server’s domain name. The --path parameter is also mandatory, and must be followed by a local URL path like /app or even /. Finally, you must give the --url parameter, followed by a URL to forward to like http://www.foo.com.

Adds a per-directory proxy to some domain#

A proxy maps some URL on a virtual server to another webserver. This means that requests for any page under that URL path will be forwarded to the other site, which could be a separate machine or another webserver process on the same system.

The --domain parameter must be given and followed by a virtual server’s domain name. The --path parameter is also mandatory, and must be followed by a local URL path like /app or even /. Finally, you must give the --url parameter, followed by a URL to forward to like http://www.foo.com.

If running Apache 2.0 or later with the mod_proxy_balancer module, the --url parameter can be given multiple times. Your webserver will then round-robin balance requests between all the URLs, which should serve the same content. This is useful for load-balancing between multiple backend servers.

If you want to turn off proxying for some URL path, the --no-proxy flag can be given instead of --url. This is useful if you have proxying enabled for / but want to serve content for some sub-directory locally.

Command line help#

virtualmin create-proxy --domain domain.name
 --path url-path
 --url destination [--url destination]*
 [--balancer name]
 --no-proxy

Source: https://www.virtualmin.com/docs/development/api-programs/create-proxy/

  • virtualmin, apache, domain, command line, module, create, proxy
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Pre and Post Domain Modification Scripts

Virtualmin allows the use of custom scripts (Shell, Perl, Python and etc.) to automate tasks...

OS Support

Virtualmin runs on top of Webmin. Webmin works on almost every UNIX-like OS, so with some manual...

Professional Features

Virtualmin GPL is already an extremely powerful and flexible virtual hosting control panel, so...

How to Configure Secondary DNS

This guide provides administrators with a quick overview of setting up automatic DNS secondary...

How to Configure Cloudflare DNS

For users looking to integrate Cloudflare with Virtualmin Pro, the process is straightforward and...