Permalink question (rewriting/redirecting old gallery contents)

AI-generated summary

Roi is seeking help to redirect old gallery image URLs (e.g., https://www.domain.tld/gallery/image/1234) to a new domain (https://www2.domain.tld/gallery/image/1234) after migrating their forum to Discourse. The old forum is now read-only, but image links must remain accessible via search engines. pfaffman clarifies that since these URLs are not Discourse-generated, permalinks won’t help. Instead, they suggest using the ‘remap take task’ to replace the old domain string in all posts, referencing the guide Replace a string in all posts. The goal is to preserve image accessibility without breaking existing links.

Hello,

I just do not understand it, but it really must be simple. So I decided to ask here. :wink:

In the old forum there was a gallery which I want to keep accessible on a new domain.

Old: https://www.domain.tld/gallery/image/1234
New: https://www2.domain.tld/gallery/image/1234

Old: https://www.domain.tld/gallery/image/1234/medium
New: https://www2.domain.tld/gallery/image/1234/medium

Old: https://www.domain.tld/gallery/image/1234/source
New: https://www2.domain.tld/gallery/image/1234/source

1234 is a number between 1 and 9999.
Discourse now runs on the old domain and I moved the old forum to the new domain and locked to read-only. But the images should be accessible, also through the search engines.

What do I need to set in Discourse to have all these links rewritten/redirected to the old forum?

Thank a lot and regards,
Roi

Those are not discourse urls, so permalinks can’t help.

You’re saying that in your discourse forum, you linked to these images and now you have moved where those images are?

The remap take task should work, I think. Replace a string in all posts