How to use ‘undo change timestamp’ custom rake task?

You need to do it inside the container.

cd /var/discourse
./launcher enter app

If you can do it from the UX instead as one of the above posts suggests, that’s what I would recommend.

You also need to create a file with that code in it, with nano, perhaps.