• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Resolved Bind subdomain to main domain without creating a different site

bradhead

New Pleskian
Server operating system version
windows 2019
Plesk version and microupdate number
Plesk Obsidian Web Host Edition 18.0.57 Update #1
Hi,

I have a website for mydomain.com which isn't ready to go live just yet. Temporarily I'd like to use temp.mydomain.com to preview the site until it's ready to go live. In Plesk I've created a domain mydomain.com and uploaded the website files to it. Now I'd like to bind the 'temp' subdomain so that it points to this site, so we can use it for preview until we're ready to switch the DNS for the main domain, but when I create a subdomain in Plesk it seems to create a whole new empty site. I effectively just want to add a binding of temp.mydomain.com to the mydomain.com domain, like you would in IIS.

Is this possible or do I need to scrap mydomain.com, create temp.mydomain.com as a new subdomain from scratch and then upload the site/database again there, then try to figure out how to change that subdomain back to a 'full' domain when ready to go live? It feels like that is quite a hassle for something seemingly so trivial, so I feel I must be missing something!

Does anyone know if it's possible to just bind a subdomain to an existing website in Plesk?

Many thanks for any help folks.
 
I think you can do it by adding "temp" as an alias, but deselecting the 301 redirect option from the alias settings, so that you get a real alias, not a redirect.
 
Thanks. I feel like aliases only let you use TLDs. In the end I've been able to get it to work by adding a subdomain to the main domain and using 'httpdocs' as the root file path (which is the same as the main domain). It still feels 'wrong' as Plesk gives it its own 'site' but it appears to work!
 
Back
Top