Assets broken after moving installation to subdomain


(Stefan Sobering) #1

Hey guys,

I setup a Discourse instance on DigitalOcean using the discourse_docker repo. For the first few weeks we had it running at the root of our domain, but have since moved to a subdomain, which we should have done from the start.

Everything seems to be working fine, with the exception of uploaded assets. All images still reference //example.com/uploads/... instead of //foo.example.com/uploads/...

This isn’t the end of the world as I’m going to be sending all assets to S3 within the next few days, but fixing the existing assets would be nice.

Thanks to anyone who can help out!

EDIT: Just noticed that Discourse.BaseUrl still reflects the root domain. This is likely what’s causing the issue?


(Kane York) #2

(Jeff Atwood) #3

Beware, s3 support (except for backups) is slated for removal in the current beta, 1.3.


(Stefan Sobering) #4

Thanks for the heads up!


(Temmyhlee) #5

Hello there, can I get link to a guide to do this?


(Régis Hanol) #6

A guide to do what exactly?


(Temmyhlee) #7

To move from example.com to forum.example.com.


(Régis Hanol) #8

is still relevant.


(Stefan Sobering) #9

I no longer run the forum that I initially did this on, but I’ll try and remember and get back to you. Sorry this answer isn’t helpful at the moment.


(Temmyhlee) #10

Thanks, will try this out and let you know how it goes.


(Temmyhlee) #11

Thanks you have been of help.