Create symlink from domain web directory to another domain web directory

Discussion in 'Installation/Configuration' started by Poliman, Oct 6, 2017.

  1. Poliman

    Poliman Member

    I have two domains. I would like to have something like this:
    I enter in web browser and I have open site from proper web directory. I have and after enter in web browser this address I need have opened website but in URL I need have I found out how to do it. I need create symlink in to web directory of domain. Unfortunatelly it's impossible, because there is currently one web directory but I can't rename it (as root it's impossible as well), I can't do enything with it. How could I resolve the issue? Maybe should I change DocumentRoot in vhost of
  2. ISPConfig Developer ISPConfig Developer

    what's wrong with using domain alias?
    Btw. you can't modify the web-folder because of immutable bit set, which can be changed on system config but it's not adviseable to do so
  3. Poliman

    Poliman Member

    Problem is that both domains are created under Website tab. So is it possible with symlink? Btw does the domain alias can provide different URL in address bar but this same content loaded? Second thing -> option Aliasdomain or maybe Aliasdomain (vhost)? If option with symlink is not possible I will try Aliasdomain but which one option. :)
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Then delete domain 2 and add it as alias.

    that's exactly what a domain alias is.
  5. ISPConfig Developer ISPConfig Developer

    yes, domain won't be changed and it's the same content beeing displayed.
    However you might want to change the aliasdomain behaviour
    enable system => Main config => Create aliasdomains as web site
    this allows you to add an aliasdomain (vhost) as websites.
    It'll ask for a document-root, use /web/

    this way you can have valid ssl for both domains

    edit: oh and do what @till suggested first ;)
  6. Poliman

    Poliman Member

    Ok, I will do it. Appreciate quick and substantive answers. Which option should I choose: Aliasdomain or Aliasdomain(vhost)? I need that aliasdomain would has ssl, so I think second option will be good in this case. Am I right?

    PS You add your answer with part which answered my question from this post. :p
  7. ISPConfig Developer ISPConfig Developer

    haha yeah :)
    you want to use aliasdomain(vhost) - the other option does not provide ssl setup

    Attached Files:

  8. till

    till Super Moderator Staff Member ISPConfig Developer

    Both options provide SSL. It depends on your SSL cert which one is right.

    - For letsencrypt, choose aliasdomain.
    - If you have a multidomain ssl cert from another ssl authority, choose aliasdomain.
    - If you have two separate ssl certs from another ssl authority, then choose aliasdomain vhost.
  9. ISPConfig Developer ISPConfig Developer

    ah yeah these wild wildcard certs, didn't have that in mind right now, thx for mentioning @till
  10. Poliman

    Poliman Member

    Currently has LE and uses redirect 301 to domain2. At the begin of creation both webdomains both had LE. Curretly only domain2 has it. I need to have both domains using LE but I don't know which option is proper - each domain has own LE cert or they use one LE cert, because one domain is an alias for second one.
  11. HSorgYves

    HSorgYves Active Member HowtoForge Supporter

    IMHO, it doesn't matter, the user sees a cert, that's all that matters...
  12. Poliman

    Poliman Member

    Second thing I have both - and created via Website tab. Both have also created shell user. Both use this same database. Should I remove shell user which belongs to domain which has to be removed (and then create an alias) ?
  13. Poliman

    Poliman Member

    Ok, so I added aliasdomain under "Aliasdomain for website" and domain which is an alias doesn't use main domain ssl cert. "https" is crossed out but - of course - I have nicely opened content from main domain. This part is finished but still problem with LE ssl.

    Probably I need use "Aliasdomain (Vhost)" but how should looks the path for web folder in "Web folder" input?

    I just put in above path "web". Now I am trying setup LE ssl.
    Last edited: Oct 10, 2017

Share This Page