Why does my Discourse crash (502 Bad Gateway) after "./launcher rebuild app"?

My vanilla install of Discourse as One-Click Install App now crashed three times. Why?

The first two times I thought this might my mistake and that ./launcher rebuild app may not be allowed in this One-Click Install App. Those first two were for corrections to app.yml that I wanted to save.

But the third was after updating from inside Discourse, so a necessary final step.

My question put another way: How can I successfully edit app.yml and should I do updates from inside Discourse?

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Our one-click uses a very standard installation of Discourse using docker and should be rebuildable using standard methods. If the app has been crashing, the first thing I would check is whether you are running out of memory on the droplet causing services to crash.

As part of the one-click setup process we build a new app.yml and use the following process to fully reconfigure (this is done by the script that is run when you first log in)

cd /var/discourse;
./launcher destroy app;
rm -f  /var/discourse/shared/standalone/redis_data/redis.rdb;
rm -Rf /var/discourse/shared/standalone/nginx;
rm -Rf /var/discourse/shared/standalone/html;
./launcher start app;