6
0
mirror of https://github.com/ChristianLight/tutor.git synced 2024-12-12 06:07:56 +00:00

Fix DoesNotExist error on android credentials creation

In some environments, the login_service_user may not be available. Thus,
we create a dedicated android user for the mobile app.

See
https://discuss.overhang.io/t/upgrading-to-juniper-fails-with-user-matching-query-does-not-exist/678
This commit is contained in:
Régis Behmo 2020-06-17 15:14:27 +02:00
parent 3956abb9aa
commit a88d9cfc19

View File

@ -5,12 +5,13 @@ echo "Loading settings $DJANGO_SETTINGS_MODULE"
./manage.py lms migrate ./manage.py lms migrate
# Create oauth credentials for Android application # Create oauth credentials for Android application
./manage.py lms manage_user android android@openedx --staff --superuser
./manage.py lms create_dot_application \ ./manage.py lms create_dot_application \
--client-id android \ --client-id android \
--client-secret {{ ANDROID_OAUTH2_SECRET }} \ --client-secret {{ ANDROID_OAUTH2_SECRET }} \
--grant-type password \ --grant-type password \
android \ android \
login_service_user android
# Fix incorrect uploaded file path # Fix incorrect uploaded file path
if [ -d /openedx/data/uploads/ ]; then if [ -d /openedx/data/uploads/ ]; then