Skip to content

Commit 5351c14

Browse files
committed
Add fixtures to review apps
1 parent 19e9362 commit 5351c14

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

app.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
}
3737
},
3838
"scripts": {
39-
"postdeploy": "./manage.py shell -c \"from django.contrib.auth import get_user_model; User = get_user_model(); User.objects.create_superuser('admin', '$EMAIL_ADMIN', 'admin')\""
39+
"postdeploy": "./postdeploy.sh"
4040
},
4141
"success_url": "/admin/login/?next=/admin/core/user/1/password/"
4242
}

postdeploy.sh

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
if [[ -z "${IS_REVIEW_APP}" ]]; then
2+
./manage.py shell -c "from django.contrib.auth import get_user_model; User = get_user_model(); User.objects.create_superuser('admin', '$EMAIL_ADMIN', 'admin')"
3+
else
4+
./manage.py loaddata fixtures/fixtures.json
5+
fi

0 commit comments

Comments
 (0)