Possible to change panel URL only ?

For questions about the usage of KeyHelp and the configuration of it services.
Post Reply
amarc
Posts: 22
Joined: Thu 7. May 2020, 18:56

Possible to change panel URL only ?

Post by amarc »

Hello,

I know I can change hostname but that also changes for example Postfix's hostname which I would rather keep at something else..

I usually do panels like admin.domain.com but prefer to have MX's as mx?.domain.com

Is something like this possible ?
User avatar
Alexander
Keyweb AG
Posts: 2608
Joined: Wed 20. Jan 2016, 02:23

Re: Possible to change panel URL only ?

Post by Alexander »

Hello,

you can rename the server with the "Hostname" feature. After that, create a new domain (preferably unter a separate user) and assign a lets encrypt certificate. Additionally you can create a redirect from this domain to the new login URL of your KeyHelp Panel.

Now you can use the new and the old name, like nothing has changes.
Mit freundlichen Grüßen / Best regards
Alexander Mahr

**************************************************************
Keyweb AG - Die Hosting Marke
Neuwerkstr. 45/46, 99084 Erfurt / Germany
http://www.keyweb.de - http://www.keyhelp.de
**************************************************************
amarc
Posts: 22
Joined: Thu 7. May 2020, 18:56

Re: Possible to change panel URL only ?

Post by amarc »

So basically I change domain to one I want under MX records/Postfix under Hostname option than I create user, create admin.domain.com under that user and than chose Forwarding with destination address I previously set under Hostname ?
User avatar
Alexander
Keyweb AG
Posts: 2608
Joined: Wed 20. Jan 2016, 02:23

Re: Possible to change panel URL only ?

Post by Alexander »

Yes.

You can always access KeyHelp with the IP, if something goes wrong, so you are able to revert the changes in that case.
Please note the sentence about HSTS below the "Hostname" input field: You may probably need to delete your browser cache.
Mit freundlichen Grüßen / Best regards
Alexander Mahr

**************************************************************
Keyweb AG - Die Hosting Marke
Neuwerkstr. 45/46, 99084 Erfurt / Germany
http://www.keyweb.de - http://www.keyhelp.de
**************************************************************
amarc
Posts: 22
Joined: Thu 7. May 2020, 18:56

Re: Possible to change panel URL only ?

Post by amarc »

Thanks.. but that is only "uggly" hack to redirect 1st time visit to another URL. I guess there is no way to preserve URL in bar.

Something to maybe implement in future releases :)

A.
User avatar
Tobi
Community Moderator
Posts: 1983
Joined: Thu 5. Jan 2017, 13:24

Re: Possible to change panel URL only ?

Post by Tobi »

You could use Apache proxy.
Then the URL stays as it is.

You´ll find several topics about Apache proxy on this board
Gruß,
Tobi


-----------------------------
wewoco.de
Das Forum für Reseller, Digital-Agenturen, Bildschirmarbeiter und Mäuseschubser
amarc
Posts: 22
Joined: Thu 7. May 2020, 18:56

Re: Possible to change panel URL only ?

Post by amarc »

Yeah.. I am getting Status 500 with something like this under Domain>Apache Settings> Directives for HTTPS:


ProxyPass / https://mx2.domain.com
ProxyPassReverse / https://mx2.domain.com/


mx2.domain.com is actual panel url (Hostname)
User avatar
Jolinar
Community Moderator
Posts: 2177
Joined: Sat 30. Jan 2016, 07:11
Location: Weimar (Thüringen)
Contact:

Re: Possible to change panel URL only ?

Post by Jolinar »

amarc wrote: Tue 10. May 2022, 20:41 I am getting Status 500
Check, if the Apache modul proxy_http is enabled

Code: Select all

a2enmod proxy_http
Wenn jemand inkompetent ist, dann kann er nicht wissen, daß er inkompetent ist. (David Dunning)
___
Ich verwende in meinen Beiträgen zwei verschiedene Schriftfarben:
  • In dieser Farbe schreibe ich als Moderator und gebe moderative Hinweise oder begründe moderative Eingriffe
  • In dieser Farbe schreibe ich als Mitglied der Community und teile meine private Meinung und persönlichen Ansichten mit
User avatar
Alexander
Keyweb AG
Posts: 2608
Joined: Wed 20. Jan 2016, 02:23

Re: Possible to change panel URL only ?

Post by Alexander »

amarc wrote: Tue 10. May 2022, 17:16 Thanks.. but that is only "uggly" hack to redirect 1st time visit to another URL. I guess there is no way to preserve URL in bar.
According to your thread title
Possible to change panel URL only ?
and your initial text
I know I can change hostname but that also changes for example Postfix's hostname which I would rather keep at something else..
My solution is perfectly valid and i would not consider it hacky at all. If this is not the solution you looked for, you may need to specify what solution you are looking for.

The "redirect" was just a bonus and I have only mentioned it for convenience for your customers.
-> You wanted an other panel URL (i assume for log in) that's what you've got when changing the Hostname.
-> You wanted to keep the MX and etc. that's what you achieve when creating a new domain with the old name.
Mit freundlichen Grüßen / Best regards
Alexander Mahr

**************************************************************
Keyweb AG - Die Hosting Marke
Neuwerkstr. 45/46, 99084 Erfurt / Germany
http://www.keyweb.de - http://www.keyhelp.de
**************************************************************
amarc
Posts: 22
Joined: Thu 7. May 2020, 18:56

Re: Possible to change panel URL only ?

Post by amarc »

I am looking for:

- Set Hostname to mx.domain.com
- Set panel (HTTP/HTTPS) URL to admin.domain.com
- Make admin.domain.com permanenent not only one time redirection to mx.domain.com

Creating admin.domain.com domain and redirecting it to https://mx.domain.com makes no sense to me as any action/click after that would be on https://mx.domain.com and in that case I could just give users panel URL in form of https://mx.domain.com

Would make sense (IMO) to make something in settings like:

- Change Panel URL (which would change only that and change this under Apache only in /etc/apache2/keyhelp/keyhelp.conf)
- Change Hostname > change /etc/hostname and anything related to that ie. Postfix/Dovecot/etc (which currently this setting is doing)

Again, not sure how this affects backend but seems sane to me from here. :)

A.
amarc
Posts: 22
Joined: Thu 7. May 2020, 18:56

Re: Possible to change panel URL only ?

Post by amarc »

Simple solution for this is to:

- Edit /etc/apache2/keyhelp/keyhelp.conf

- Add ServerAlias like so

Code: Select all

# KeyHelp / Tools
<VirtualHost *:443>
    ServerName mx2.domain.com
    ServerAlias admin.domain.com
    ServerAdmin root@mx2.domain.com
Now probably this will be overwritten on update(s) ? But something I can live with and adjust from time to time..
Post Reply