Hi,
What is the way to Rebuild HTML for all posts?
Thank you.
3 Likes
Lilly
October 16, 2023, 3:12am
2
I think you need to use rails to re-bake your posts. this can be a resource-intensive operation depending on the number of posts on your forum, so best do it during off-peak hours. Also backup first.
Either one of these should work
./launcher enter app
rake posts:rebake
or
cd /var/discourse
./launcher enter app
bundle exec rake posts:rebake
Better if you can somehow do this:
Want to rebake all the posts matching a string or regular expression? Let’s do it!
Access Your Site
First connect to your Droplet via SSH, and enter the Docker container for your Discourse instances:
cd /var/discourse
./launcher enter app
Rebake All Posts Containing a Specific String
Run this command:
rake posts:rebake_match["pattern"]
Replace pattern with the string you want to match. Note that the match performed will be case insensitive.
rake posts:rebake_match[" "]
The ab…
7 Likes
system
(system)
Closed
November 15, 2023, 3:13am
3
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.