I installed traccar on GPS server from https://www.traccar.org/install-digitalocean/
how to setup subdomain config to make it work properly
I need to redirect the subdomain like this
https://gps.zaka.biz -> http://server_ip:portnumber/login
How to redirect subdomain to server local port? [SOLVED]
How to redirect subdomain to server local port? [SOLVED]
Last edited by Natig on Thu 29. Dec 2022, 20:03, edited 2 times in total.
Re: How to redirect subdomain to server local port?
Hello,
you must use mod_proxy.
Enable proxy_http module in the Apache Webserver and set the required proxy rules in the tab "apache settings" (use the pencil symbol behind the domain/subdomain name)
e.g.
Ther first lines make sure that you can use Let's Encrypt on a domain that uses mod_proxy
you must use mod_proxy.
Enable proxy_http module in the Apache Webserver and set the required proxy rules in the tab "apache settings" (use the pencil symbol behind the domain/subdomain name)
e.g.
Code: Select all
<IfModule mod_proxy.c>
ProxyPass /.well-known/acme-challenge !
</IfModule>
Alias /.well-known/acme-challenge /home/keyhelp/www/.well-known/acme-challenge
ProxyPass / http://127.0.0.1:Portnumber/
ProxyPassReverse / http://127.0.0.1:Portnumber/
Ther first lines make sure that you can use Let's Encrypt on a domain that uses mod_proxy
Mit freundlichen Grüßen / Best regards
Florian Cheno
**************************************************************
Keyweb AG - Die Hosting Marke
Neuwerkstr. 45/46, 99084 Erfurt / Germany
http://www.keyweb.de - http://www.keyhelp.de
**************************************************************
Florian Cheno
**************************************************************
Keyweb AG - Die Hosting Marke
Neuwerkstr. 45/46, 99084 Erfurt / Germany
http://www.keyweb.de - http://www.keyhelp.de
**************************************************************
Re: How to redirect subdomain to server local port?
Thanks a lot, everything worked great.