How do I run Discourse on Pterodactyl Panel?

If there is you are not likely to get help with it here.

The only supported way to install Discourse is How to install Discourse in production. I recommend that you do a clean installation of Ubuntu without the egg thing and follow that guide.