Now, I want to configure virtual hosts (I bought a domain name) to display http://www.domain.eu instead of http://<MyBookIP>.
I saw I have to configure ligthppd.conf, I read the lighttpd doc but it doesn't make sense for me ($HTTP isn't in the file !)

Hi newtof, your problem has nothing to do with virtual hosting…
and it is not a configuration of your Mybooko that controls if your url is changed into an ip address or not.

You should restore the working lighttpd.conf and check your DomainName Configuration,
on your Provider's web interface for managing your Domain Name.

you have probably a wrong configuration on your Domain Name : (check your Domain Name Provider )

There are 2 types of configuration for your domain Name :
- DNS Declaration of your Public Ip Address ( then, your name will remain, as you want https://www.myfomain.com )
- Http forwarder ( when browsing to the name, you are forwarded to the ip ( you are in this wrong situation)

==> to solve your problem, you do not need to touch the lighttpd.conf file at all.
You need to check the options that you have on your Domain Name Provider…

Note : Virtual hosting is only usefull if you have 2or 3 domain NAmes : www.MydomainNAme1, www.MyDomainName2, www.MyDomainName3
and you want that your Mybook handles differently those 3 domain Names. If it is not your case, then you should'nt implement virtual hosting.

OK my DNS are ok now, I need your help for the last point (maybe TeinturMan you're the best to answer me), what I want :
- www.mydomain.eu goes to $SERVER["socket"] == ":8080"
- photo.mydomain.eu goes to $SERVER["socket"] == ":443"

if you do not want to have the :8080 at the end of your url, there are 2 solutions :
Solution A : on your Home Router , if it has an advanced configuration, forward port TCP 80 to your internal Mybook , port 8080.
Solution B : On the Original Lighttpd.conf, change the port for the Western Digital Interface to 81 by modifying the line :
$SERVER["socket"] == ":80" {
with
$SERVER["socket"] == ":81" {

then modify the line
$SERVER["socket"] == ":8080" {
with the line
$SERVER["socket"] == ":80" {

then restart the Web Server
then configure your Home Router to forward port 80 to your internal Mybook, port 80.

Because, if I put in address "photo.mydomain.eu" lighttpd choose the http port (8080 in my case due to port 80 redirection with my router) and I want it chooses 443 port (https)

2) If I type "photo.mydomain.eu" or "www.mydomain.eu" I gain the same page : the public page on port 80(http). Now, I want that lighttpd choose by checking the subdomain what type of protocol it needs to use and redirect "photo.mydomain.eu" to "https://photo.mydomain.eu" and not "http://photo.mydomain.eu"

Is it possible to do that ?

3) And if I need 2 subdomains in http protocol:
- www : public page
- test : an other page

when you want to access a web server, you always need to indicate the protocol ( http:// or https:// )
if you do not indicate it , INTERNET EXPLORER will add http:// automatically. This is why your both urls goes to the public web site.

it is not lighttpd which will translate your name to the correct protocol….
Internet Explorer will have added http:// as soon as you have typed the photo.mydomain.eu in the url bar.

Really, i would say the best way to configure your remote access is to define a single name , and you type

I finally found…Your last method is good TeinturMan, I've just put "mod_evhost" in server.modules and I've found that the web server doesn't support html extension (not index.html, but index.php works). So, the extension need to be .php for files and it's works!