https://github.com/rostopira/parse-server-alibaba-oss-adapter
Parse Server adapter for AlibabaCloud Object Storage Service
https://github.com/rostopira/parse-server-alibaba-oss-adapter
alibaba-oss parse-server
Last synced: 4 months ago
JSON representation
Parse Server adapter for AlibabaCloud Object Storage Service
- Host: GitHub
- URL: https://github.com/rostopira/parse-server-alibaba-oss-adapter
- Owner: rostopira
- License: wtfpl
- Created: 2019-07-09T13:01:49.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-06T19:05:17.000Z (over 3 years ago)
- Last Synced: 2024-10-19T07:54:57.606Z (over 1 year ago)
- Topics: alibaba-oss, parse-server
- Language: JavaScript
- Homepage:
- Size: 55.7 KB
- Stars: 2
- Watchers: 1
- Forks: 1
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# parse-server-alibaba-oss-adapter
Parse Server adapter for AlibabaCloud Object Storage Service
# Installation
`npm install git+https://git@github.com/rostopira/parse-server-alibaba-oss-adapter.git`
# Usage
```
const OSSAdapter = require('parse-server-alibaba-oss-adapter');
new ParseServer({
// Other options
// Example config, change every field (=
filesAdapter: new OSSAdapter({
"region": "oss-cn-beijing",
"accessKeyId": "XXX",
"accessKeySecret": "AAA",
"bucket": "mybucket",
"internal": true, //set to true, if running inside VPC, defaults to false
"secure": false //defaults to !internal``
})
});
```
### Using environment variables
Set your environment variables:
```
OSS_REGION=oss-cn-beijing
OSS_ACCESS_KEY_ID=XXX
OSS_ACCESS_KEY_SECRET=AAA
OSS_BUCKET=mybucket
OSS_INTERNAL=true
OSS_SECURE=false
```
And update your config / options
```
const OSSAdapter = require('parse-server-alibaba-oss-adapter');
new ParseServer({
// Other options
filesAdapter: new OSSAdapter()
});
```