Manual adding of new users
-
wrote on Dec 2, 2024, 1:03 PM last edited by
Supposedly one can add new users in Discourse via the terminal as in:
./launcher enter app rails c user = User.create!(username: 'newusername', email: 'user@example.com', password: 'password', active: true)
Is there a "translation" to the Cloudron world?
Cheers -
Can you add more info an docs links, where this is from and which environment this expects? Have you tried to get this working via the webterminal into your discourse instance?
https://docs.cloudron.io/apps/discourse/#changing-root-account-email has an example on how to get a rails prompt, which might help here
-
wrote on Dec 2, 2024, 1:39 PM last edited by
This is for admins - but should work for anyone else -> https://meta.discourse.org/t/create-an-admin-account-from-the-console/17274 ; I guess it is equivalent to your link.
Yes, I'd tried the console but wasn't sure how to do the "create" new user bit ...#
Thanks and regards! -
wrote on Dec 2, 2024, 2:37 PM last edited by
OK. Found another meta.discoures post on the subject -> https://meta.discourse.org/t/how-to-manually-add-users-and-email-in-console-mode/26669/2 ; might explain the how-to?
-
The commands below on the discourse Web terminal should get you the rails console.
cd /app/code gosu cloudron:cloudron bundle exec script/rails console