Skip to content

Commit

Permalink
Define aws credentials as django settings
Browse files Browse the repository at this point in the history
  • Loading branch information
walison17 committed Nov 8, 2023
1 parent 896e943 commit 3cda7aa
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions example/example/settings.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import os
from pathlib import Path

# Build paths inside the project like this: BASE_DIR / "subdir".
Expand Down Expand Up @@ -26,9 +27,10 @@
}
}

# AWS credentials (AWS_S3_ACCESS_KEY_ID / AWS_S3_SECRET_ACCESS_KEY) are defined
# in .github/workflows/example-test.yml as environment variables.
AWS_STORAGE_BUCKET_NAME = "example-migrateci-cache"
AWS_S3_REGION_NAME = "us-east-2"

AWS_ACCESS_KEY_ID = os.getenv("AWS_ACCESS_KEY_ID")
AWS_SECRET_ACCESS_KEY = os.getenv("AWS_SECRET_ACCESS_KEY")

MIGRATECI_STORAGE = "storages.backends.s3boto3.S3Boto3Storage"

0 comments on commit 3cda7aa

Please sign in to comment.