Last active
February 22, 2024 01:58
-
-
Save mitchtabian/17d97370d92d1dfdeaca40fa94c1e227 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
INSTALLED_APPS = [ | |
# My apps | |
'personal', | |
'account', | |
'blog', | |
# django apps | |
'django.contrib.admin', | |
'django.contrib.auth', | |
'django.contrib.contenttypes', | |
'django.contrib.sessions', | |
'django.contrib.messages', | |
'django.contrib.staticfiles', | |
'storages' | |
] | |
AUTH_USER_MODEL = 'account.Account' | |
AWS_ACCESS_KEY_ID = 'M5YCPZP3QT36OWMMZS23' | |
AWS_SECRET_ACCESS_KEY = '5Npq/S/7tX2IqBl51p3QEAMJuuGvHuFH4680Cl59M3s' | |
AWS_STORAGE_BUCKET_NAME = 'open-api-space' | |
AWS_S3_ENDPOINT_URL = 'https://nyc3.digitaloceanspaces.com' | |
AWS_S3_OBJECT_PARAMETERS = { | |
'CacheControl': 'max-age=86400', | |
} | |
AWS_LOCATION = 'open-api-static' | |
STATICFILES_DIRS = [ | |
os.path.join(BASE_DIR, 'static'), | |
] | |
STATIC_URL = 'https://%s/%s/' % (AWS_S3_ENDPOINT_URL, AWS_LOCATION) | |
STATICFILES_STORAGE = 'storages.backends.s3boto3.S3Boto3Storage' | |
DEFAULT_FILE_STORAGE = 'storages.backends.s3boto3.S3Boto3Storage' |
nice snippet
Sir How to Manage Media files Sir
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
plz write here to manage media files Sir