Backends - GetmeUK/hangar51 GitHub Wiki
Backends
Hanger51 currently supports 2 backend storage options local
file system and AWS s3
. When you create an account you must specify a backend configuration file so the account knows how to store assets and each backend has it's own set of configuration options for storage.
Local file storage
Local file storage is not recommended for production (accept for perhaps on smaller projects) and is provided for the most part to make it easy to run Hanger51 on your local machine while testing.
Config:
- backend must be
'backend'
- asset_root the root directory path where the application will store assets.
{
"backend": "local",
"asset_root": "/my/assets"
}
AWS s3 storage
s3 is the recommended storage backend for production environments along with the use fo a CDN such as cloudfront to provide access to assets.
Config:
- backend must be
's3'
- access_key the access key for your s3 account.
- secret_key the secret key for your s3 account.
- bucket the bucket where the application will store assets.
{
"backend": "s3",
"access_key": "MY_ACCESS_KEY",
"secret_key": "MY_SECRET_KEY",
"bucket": "mybucket"
}