Permanent modification of ips.conf

Mikolo

Verified User
Joined
Mar 30, 2023
Messages
6
I would like to show the webpage on IP address.

I modified the file: /etc/httpd/conf/ips.conf

From:
Apache config:
ServerName shared.domain
DocumentRoot /home/admin/domains/sharedip
To:
Apache config:
ServerName 10.10.10.10
DocumentRoot /home/admin/domains/example.com/public_html

It works, but in a file, I see information that "any changes you make will be overwritten when you add/remove ip's through DirectAdmin."

Maybe someone has an idea of how I can setup it permanently?
 
Hello,

Check https://docs.directadmin.com/webservices/apache/customizing.html for an information on how to customize files under /etc/httpd/conf/
Hi,

Thank you for the link.

1. I have done suggestions from point 1 - "official way"
2. I copied ips.conf from /etc/httpd/conf/ips.conf to /usr/local/directadmin/custombuild/custom/ap2/conf/
3. I made changes in /usr/local/directadmin/custombuild/custom/ap2/conf/ips.conf
4. I executed ./build rewrite_confs

But I don't see any changes. So I'm guessing the config doesn't load from this new file.

Can anyone help?
 
You can create own config and include it, instead of modifying general config.
 
ips.conf loaded from IP Management that come with option "Linked IPs : Added to Apache", ( no matter you use nginx or apache, it still same option)
 
Maybe someone knows how to display the page at the IP address and set it permanently so that DirectAdmin does not overwrite the settings?
 
If you make an IP owned by an user, you can access a webroot via IP. Is it an option for you?
I have assigned IP addresses to the user (as in the attached picture). What do you mean "you can access a webroot via IP"
 

Attachments

  • 2023-04-27 10_28_39-Window.png
    2023-04-27 10_28_39-Window.png
    18.7 KB · Views: 29
Back
Top