View more context

 

taoceanz

How do you configure it to know where to look/how to connect to S3? Is it just variables in .env or server env vars for region, bucket name, access key id and secret access key?

thats4shaw

Yep, environment vars. Well last time I played with it.

thats4shaw

Server environment vars are probably more desirable.

dorsetdigital
  1. ---
  2. Only:
  3. envvarset: AWS_BUCKET_NAME
  4. After:
  5. - '#assetsflysystem'
  6. ---
  7. SilverStripe\Core\Injector\Injector:
  8. Aws\S3\S3Client:
  9. constructor:
  10. configuration:
  11. region: '`AWS_REGION`'
  12. version: latest
  13. credentials:
  14. key: '`AWS_ACCESS_KEY_ID`'
  15. secret: '`AWS_SECRET_ACCESS_KEY`'
taoceanz

Readme says full details on env vars can be seen in SilverStripeS3AdapterTrait though that doesn't appear to exist

dorsetdigital

That's the YML I use... and that picks up from the env vars

dorsetdigital

My local dev copy just uses the local file system, as I don't have the bucket name set in the .env file