Change URL for Foreman

Problem:
I try to change url address foreman web interface but my attemptsс failed
Expected outcome:
We use link https://foreman.domain.com but we try to change on https://foreman-domain.com
Foreman and Proxy versions:
We use The Foreman 3.9.1 versions and Smart Proxy
Foreman and Proxy plugin versions:

Distribution and version:

Other relevant data:
I tried to change the settings of hostname and /etc/hots/ and restart the installation of forman with the url parameter
got an error with certificates
I tried to change the settings in /etc/foreman/settings.yml and /etc/foreman-proxy/settings.yml by replacing the links with the correct ones, but it still didn’t work. I was advised to change the ServerName in the apache2 configuration, so I did that and restarted apache2 and foreman, foreman-proxy, but it didn’t make any difference except that the nodes lost connection to papeton and forman. Perhaps it is worth making changes in the interactive installation menu foreman-installer -i ? But on some attempts I was pushed out of the advanced settings

Hi @SkipuaPy

There is a docs page for exactly this case :slight_smile:

https://docs.theforeman.org/3.9/Administering_Project/index-katello.html#renaming-foreman_admin

1 Like

Hi @lumarel, my Foreman is running on Debian 11.9, is this guide suitable for my case? Katello does not work with Foreman installed on Debian?

Thank you for the answer
Best Regards.

Oh okay yeah this does not apply to systems without Katello, that’s true :confused:

What do you think about redirecting foreman.mydomain.com to foreman-mydomain.com for example? Is it possible?

Tbh I never had to do this, especially not in a non Katello environment,
but as far as I understand it, you just supply foreman-installer with the new hostname variable and then it will change it everywhere necessary, make sure you also provide a new certificate though.
Also depending on your installation, if you installed the Puppet Add-on (or also Salt) that will be a bit of another story, because the clients have the domain imprinted in their local configuration (as well I’m not sure if the Puppet CA will handle a hostname change gracefully)