Promotion from test.domain.com to www.domain.com

19 views
Skip to first unread message

James Morse

unread,
Mar 6, 2020, 11:10:11 AM3/6/20
to Mezzanine Users
Greetings all,
I set up my first Mezzanine site for my wife to work on as test.domain.com with the intent of that being temporary. This was so her old static HTML "production" site wasn't affected until she was done.  Last night she finally finished the site and asked me to "launch it". I pointed her @ record and www.domain.com to the new server IP hosting the Mezzanine setup and after fixing the cert, I was surprised to see the base template site/theme without any of the content she worked on.  After searching similar but not identical scenarios, I now see that Mezzanine instantiates itself for each subdomain.  Is there some way to point all her subdomains to the content she's already worked so hard on?  If not, then is there perhaps a way to migrate the test.domain.com site content to the @ or www. subdomain "new" site?  I've seen the responses that reference using Nginx or similar to redirect all to x.domain.com but in this case I, of course, don't want her customers being redirected to "test.domain.com", so I need a different solution.
Thanks for your time and any help you can provide!

Danny

unread,
Mar 6, 2020, 4:51:29 PM3/6/20
to mezzani...@googlegroups.com

Have you logged into the admin, and updated the default 'Site' to the 'www.domain.com'?  Mezzanine associates each page with a 'Site' so you can serve multiple subdomains with the same database and django instance - and the URL is used for this when not in test mode.

(Basically, go to www.domain.com/admin/sites/site/ and make sure that's correct - if not, edit it)

Does that help?

I have done this before to change a test.domain.com to a live.domain.com, and it seemed to work ok. The other option you can try is to just set it to domain.com.

There might be someone else with more Mezzanine knowledge than me who can help, but I think this the best place to start checking, especially if the test domain is still working.

Seeya. Danny.

James Morse

unread,
Mar 6, 2020, 8:17:31 PM3/6/20
to Mezzanine Users
 I'm not familiar with that page. If I go there with an admin user, I do see both domain.com and test.domain.com. Two columns : Domain and Display Name. However the "display name" column is blank for test.domain.com and has "Default" beside domain.com.  The drop down at the top has ----- and can only be changed to "delete selected sites". I don't have any other options than that.

James Morse

unread,
Mar 6, 2020, 10:44:36 PM3/6/20
to Mezzanine Users
I ended up deleting the domain.com entry within that menu and relabeling test.domain.com to Default and eventually editing the domain line for that site removing "test." to make it just domain.com.  After that I added some rules to the Nginx conf to cover for anyone browsing via www.domain.com.  This mixed with a couple logouts and cache clears appears to be working as intended.
Thanks Danny for pointing me in the right direction!
Reply all
Reply to author
Forward
0 new messages