Re: localhost
On Sun, 2 Feb 2020 19:40:24 +0000
"Russell L. Harris" <russell@rlharris.org> wrote:
> I am attempting to configure Apache2 (in Debian 10) as a local server
> for web site development.
>
> I see on the "Apache2 Debian Default Page" the Debian logo; the
> browser reports the image location as:
>
> http://localhost/icons/openlogo-75.png
>
> But when I use midnight commander to snoop around \var and other
> directories, I find no directory named "localhost".
>
> The immediate goal of my investigation is to discover the location
> (with respect to "var/www" or "public_html") to which essential images
> such as web site logos and navigation button icons should be uploaded.
>
> This investigation is part of my exploration of the "Perl Template
> Toolkit". I am proceeding step-by-step through the tutorial presented
> in chapter 11 of the O'Reilly "Badger Book", but I do yet understand
> why images are not being displayed.
>
>
Localhost isn't a directory. It is the hostname from /etc/hosts. The
directory comes from what is configured
in /etc/apache2/sites-available/000-default.conf
Default is /var/www/html
So if you do:
printf "Found my localhost root directory\n" >> /var/www/html/test.txt
You can then navigate to http://localhost/test.txt and you'll see your
new message in your browser.
Reply to:
- References:
- localhost
- From: "Russell L. Harris" <russell@rlharris.org>