Hosting a separate web page on same pi as pi-hole

As above really...

I'd like to host a simple web page / site on my Pi2

It's currently being used exclusively for pi-hole and openvpn.

Is it possible to host a separate, very basic page?
Something very plain, showing pi stats for example?

I know pi-hole runs in port 80 and as far as I can make out so do all the others such as Apache.

I would only be accessing from within my network so won't need external / public access

Have you tried adding the site to /var/www/html?

Youll have to excuse my ignorance here, but what do you mean by this?

Is my 'site' contained within 1 folder?

Also, I haven't ran sudo apt-get install apache2 but I do see an apache folder in /etc/
But it contains only 1 folder titled 'mods-available'.

Is the site a file such as index.php or index.html? Anything that you put under /var/www/html/ will be available via port 80, so if you put something.html under that directory, you would be able to reach it via http://localhost/something.html. Same with directories, so if your site is contained in a folder called webpage and you put it in the /var/www/html/ folder, you can reach the pages via http://localhost/webpage/ + the name of the file.

Ah ok, I think I understand...ish.
At the moment I haven't created anything as I was worried about there being a conflict between 'mysite' and pi-hole, basically I was thinking it would hinder or 'break' pihole in some way.

But, if I understand I can create my site all within one folder, e.g. 'mysite'
this folder would go inside /var/www/html/ and inside the 'mysite' folder I would have all the necessities, e.g. homepage.html, about.html etc.

do I need to install apache via sudo apt-get install apache2 or am I good to go as is, using /var/www/html?

Thanks

You're right, just create your site and files in /var/www/html/whatever/

You don't have to install apache, because there is already an installed webserver (lighttpd) on your system.

thanks, guess id better start learning php!
my main aim is to have a very basic page with details about my Pi, uptime, temp, memory usage etc

Take a look at RPi-Monitor.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.