You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Add support for Node 20, 22; remove support for Node 14, 16 ([#226](https://github.com/parse-community/parse-server-s3-adapter/issues/226)) ([da5a94f](https://github.com/parse-community/parse-server-s3-adapter/commit/da5a94fa180ba57dfae33659e18db4704582e8e6))
7
+
8
+
9
+
### BREAKING CHANGES
10
+
11
+
* Removes support for Node 14, 16. ([da5a94f](da5a94f))
-[Passing as an Instance](#passing-as-an-instance)
28
+
-[Adding Metadata and Tags](#adding-metadata-and-tags)
29
+
-[Compatibility with other Storage Providers](#compatibility-with-other-storage-providers)
30
+
-[Digital Ocean Spaces](#digital-ocean-spaces)
26
31
27
-
# Installation
32
+
33
+
# Getting Started
34
+
35
+
## Installation
28
36
29
37
`npm install --save @parse/s3-files-adapter`
30
38
31
-
# AWS Credentials
39
+
## Compatibility
40
+
41
+
### Parse Server
42
+
43
+
| Version | End-of-Life | Compatible |
44
+
|---------|---------------|------------|
45
+
| <=5 | December 2023 | ✅ Yes |
46
+
| 6 | December 2024 | ✅ Yes |
47
+
| 7 | December 2025 | ✅ Yes |
48
+
49
+
### Node.js
50
+
51
+
This product is continuously tested with the most recent releases of Node.js to ensure compatibility. We follow the [Node.js Long Term Support plan](https://github.com/nodejs/Release) and only test against versions that are officially supported and have not reached their end-of-life date.
52
+
53
+
| Version | Latest Version | End-of-Life | Compatible |
⚠️ The ability to explicitly pass credentials to this adapter is deprecated and will be removed in a future release.
34
62
@@ -55,7 +83,7 @@ For an AWS host:
55
83
56
84
If for some reason you really need to be able to set the key and secret explicitly, you can still do it using `s3overrides` as described below and setting `accessKeyId` and `secretAccessKey` in the `s3Overrides` object.
57
85
58
-
# Deprecated Configuration
86
+
##Deprecated Configuration
59
87
60
88
Although it is not recommended, AWS credentials can be explicitly configured through an options
61
89
object, constructor string arguments or environment variables ([see below](#using-a-config-file)).
@@ -65,17 +93,17 @@ The preferred method is to use the default AWS credentials pattern. If no AWS c
65
93
66
94
# Usage with Parse Server
67
95
68
-
###Parameters
96
+
## Parameters
69
97
70
98
*(This list is still incomplete and in the works, in the meantime find more descriptions in the chapters below.)*
|`fileAcl`| yes |`undefined`| S3_FILE_ACL | Sets the [Canned ACL](https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#canned-acl) of the file when storing it in the S3 bucket. Setting this parameter overrides the file ACL that would otherwise depend on the `directAccess` parameter. Setting the value `'none'` causes any ACL parameter to be removed that would otherwise be set. |
75
-
|`presignedUrl`| yes |`false`| S3_PRESIGNED_URL | If `true` a [presigned URL](https://docs.aws.amazon.com/AmazonS3/latest/dev/ShareObjectPreSignedURL.html) is returned when requesting the URL of file. The URL is only valid for a specified duration, see parameter `presignedUrlExpires`. |
76
-
|`presignedUrlExpires`| yes |`undefined`| S3_PRESIGNED_URL_EXPIRES | Sets the duration in seconds after which the [presigned URL](https://docs.aws.amazon.com/AmazonS3/latest/dev/ShareObjectPreSignedURL.html) of the file expires. If no value is set, the AWS S3 SDK default [Expires](https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/S3.html#getSignedUrl-property) value applies. This parameter requires `presignedUrl` to be `true`. |
|`fileAcl`| yes |`undefined`| S3_FILE_ACL | Sets the [Canned ACL](https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#canned-acl) of the file when storing it in the S3 bucket. Setting this parameter overrides the file ACL that would otherwise depend on the `directAccess` parameter. Setting the value `'none'` causes any ACL parameter to be removed that would otherwise be set.|
103
+
|`presignedUrl`| yes |`false`| S3_PRESIGNED_URL | If `true` a [presigned URL](https://docs.aws.amazon.com/AmazonS3/latest/dev/ShareObjectPreSignedURL.html) is returned when requesting the URL of file. The URL is only valid for a specified duration, see parameter `presignedUrlExpires`.|
104
+
|`presignedUrlExpires`| yes |`undefined`| S3_PRESIGNED_URL_EXPIRES | Sets the duration in seconds after which the [presigned URL](https://docs.aws.amazon.com/AmazonS3/latest/dev/ShareObjectPreSignedURL.html) of the file expires. If no value is set, the AWS S3 SDK default [Expires](https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/S3.html#getSignedUrl-property) value applies. This parameter requires `presignedUrl` to be `true`. |
77
105
78
-
###Using a config file
106
+
## Using a Config File
79
107
80
108
```
81
109
{
@@ -106,7 +134,7 @@ The preferred method is to use the default AWS credentials pattern. If no AWS c
106
134
```
107
135
***Note*** By default Parse.FilesController.preserveFileName will prefix all filenames with a random hex code. You will want to disable that if you enable it here or wish to use S3 "directories".
108
136
109
-
### using environment variables
137
+
##Using Environment Variables
110
138
111
139
Set your environment variables:
112
140
@@ -132,7 +160,7 @@ And update your config / options
132
160
```
133
161
134
162
135
-
### passing as an instance
163
+
##Passing as an Instance
136
164
```
137
165
var S3Adapter = require('@parse/s3-files-adapter');
138
166
@@ -209,9 +237,42 @@ var api = new ParseServer({
209
237
filesAdapter: s3Adapter
210
238
})
211
239
```
212
-
### Usage with Digital Ocean Spaces
240
+
241
+
## Adding Metadata and Tags
242
+
243
+
Use the optional options argument to add [Metadata](https://docs.aws.amazon.com/AmazonS3/latest/user-guide/add-object-metadata.html) and/or [Tags](https://docs.aws.amazon.com/AmazonS3/latest/user-guide/add-object-tags.html) to S3 objects
**Note:** This adapter will **automatically** add the "x-amz-meta-" prefix to the beginning of metadata tags as stated in [S3 Documentation](https://docs.aws.amazon.com/AmazonS3/latest/user-guide/add-object-metadata.html).
269
+
270
+
271
+
# Compatibility with other Storage Providers
272
+
273
+
## Digital Ocean Spaces
274
+
275
+
```js
215
276
var S3Adapter =require("@parse/s3-files-adapter");
Use the optional options argument to add [Metadata](https://docs.aws.amazon.com/AmazonS3/latest/user-guide/add-object-metadata.html) and/or [Tags](https://docs.aws.amazon.com/AmazonS3/latest/user-guide/add-object-tags.html) to S3 objects
**Note:** This adapter will **automatically** add the "x-amz-meta-" prefix to the beginning of metadata tags as stated in [S3 Documentation](https://docs.aws.amazon.com/AmazonS3/latest/user-guide/add-object-metadata.html).
0 commit comments