Adds a simple script to add a single user to the app #977
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Why
Previously there has not been an easy way to add a new user to the application prior to configuring a SMTP server to dispatch confirmation emails.
What
Create a rake task that
bin/rake add_user EMAIL=example@exampler.com PASSWORD=mysupersecurepassword
EMAIL
andPASSWORD
How
Omitted, as this was a very simple change.
Testing
Omitted, as this task is only meant to be run by developers in non-production environments
Next Steps
DISABLE_DATABASE_ENVIRONMENT_CHECK=1
Accessibility
Omitted, as this is a developer-only feature.
Security
This script cannot be run without administrator shell access to the server hosting the application, and anyone who has administrator shell access to the server is able to do anything they want. Therefore, security of this script isn't really relevant since any scenario where this is invoked by a bad actor is also a scenario where the bad actor can do arbitrary other things.
Pre-Merge Checklist
Also, thanks to @h-m-m for their help making this change!