Configuring Apache HTTP for changing context URL

First of all you must have one of these configurations running on your server:

 Enable the headers module:

$ sudo a2enmod headers

 To change /OpenKM application context try this as your VirtualHost configuration:

<VirtualHost *:80>
  ServerName openkm.your-domain.com
  
  ProxyPass /frontend/webSocket ws://localhost:8080/OpenKM/frontend/webSocket
  ProxyPassReverse /frontend/webSocket ws://localhost:8080/OpenKM/frontend/webSocket

  ProxyPass / ajp://localhost:8009/OpenKM/
  ProxyPassReverse / http://openkm.your-domain.com/OpenKM/

  RequestHeader edit X-GWT-Module-Base ^(http://openkm.your-domain.com)/frontend/(.*)$ $1/OpenKM/frontend/$2
  ProxyPassReverseCookiePath /OpenKM /

  ErrorLog /var/log/apache2/openkm-error.log
  CustomLog /var/log/apache2/openkm-access.log combined
</VirtualHost>

You also need to set the configuration parameter system.apache.request.header.fix to on (true). 

Additional information