This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
export PYTHONPATH=`pwd` | |
./manage.py collectstatic --noinput | |
echo Running ${1:-"update"} on ${2:-"local_zappa_settings.json"} | |
zappa ${1:-"update"} -s ${2:-"local_zappa_settings.json"} | |
zappa manage -s ${2:-"local_zappa_settings.json"} ${3:-"development"} migrate | |
zappa invoke -s ${2:-"local_zappa_settings.json"} ${3:-"development"} "from django.contrib.auth.models import User; import os; User.objects.create_superuser('root', 'mail@nomail.com', os.environ.get('DJANGO_ADMIN_PASSWORD','*****')) if len(User.objects.filter(email='mail@nomail.com')) == 0 else print('Admin exists')" --raw |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AWSTemplateFormatVersion: '2010-09-09' | |
Description: Template for Lambda Sample. | |
Outputs: | |
LambdaRoleARN: | |
Description: Role for Lambda execution. | |
Value: | |
Fn::GetAtt: | |
- LambdaRole | |
- Arn |
OlderNewer