docker-mailman icon indicating copy to clipboard operation
docker-mailman copied to clipboard

Add instructions for social login

Open maxking opened this issue 8 years ago • 13 comments

https://django-allauth.readthedocs.io/en/latest/installation.html#post-installation

Django allauth requires some setup before it starts working. It needs to be setup using the django's admin console. The process isn't very difficult but needs to be documented somewhere so that people don't expect it to work out of the box.

maxking avatar Apr 21 '17 18:04 maxking

Yes, it would be very useful to have this documented. After docker-compose up, If I open /admin/ page what user credentials should I use? Has django createsuperuser already run on this stage?

ghost avatar Jun 11 '17 13:06 ghost

The answer seems 'No'. Here is a command for creation of superuser after containers are up:

docker-compose exec -T mailman-web bash -c "echo \"from django.contrib.auth.models import User; User.objects.create_superuser('admin', '[email protected]', 'password')\" | python manage.py shell"

ghost avatar Jun 11 '17 14:06 ghost

@ulrith you can create one like this too:

docker-compose exec -T mailman-web python manage.py createsuperuser

This command is going to be interactive but will work.

I will add it to documentation. Thanks!

maxking avatar Jun 11 '17 21:06 maxking

Yes, thanks, and my command listed above is non-interactive and it works too :)

ghost avatar Jun 12 '17 06:06 ghost

@ulrith Also, getting social logins to work is a little tricky if you are doing it for the first time, let me know and I can help you get started.

maxking avatar Jun 12 '17 06:06 maxking

@maxking I'd like to accept your offer to configure social logins now :)

ghost avatar Jun 25 '17 17:06 ghost

@ulrith Sure! We should move to IRC or email?

maxking avatar Jun 26 '17 15:06 maxking

@maxking Yes thanks! I've sent an email to you

ghost avatar Jun 29 '17 18:06 ghost

This would also include instructions about how to disable social login via a custom settings_local.py.

almereyda avatar Jul 08 '17 00:07 almereyda

@almereyda It should not be very difficult to just remove all the social logins. You just change the INSTALLED_APPS to remove all the social logins.

There potentially could be an environment variable to disable it if enough people are interested to get rid of social logins by default, but for now, changing the INSTALLED_APPS in django's settings_local.py would be what I would suggest.

maxking avatar Jul 10 '17 22:07 maxking

@maxking Hi, i tried what you suggested but it didn't not work, there is any other way to disable the external sign in from social networks in HyperKitty ?

Dragnell87 avatar Aug 03 '17 20:08 Dragnell87

OK i found the solution, is as you said but, you cannot delete or comment allauth.socialaccount otherwise the migration at start up will fail.

Dragnell87 avatar Aug 04 '17 01:08 Dragnell87

@Dragnell87 Yeah that would make sense because that is the only app which uses database.

Although, you might be able to get rid of that if you use a fresh copy of database. Since migrations are expected to be generated by the apps, the migrate command would be expected to fail in case a table disappers without a migration.

python mange.py makemigrations && python manage.py migrate might work, but would have to be done on each restart.

maxking avatar Aug 04 '17 13:08 maxking

This issue has not been updated for more than 1year

github-actions[bot] avatar Dec 03 '22 22:12 github-actions[bot]