Google-cloud

Upload file to google-cloud

1- Finish this guide

Create upload service

2- Create google-cloud account

  1. Follow this 3 first steps of this guide

  2. Create secret-files folder in the src folder

  3. copy the JSON key file from google-cloud to src > secret-files and rename the file to secret-files.json

3 - new bucket

  1. Create new bucket

4- Update config json

path: config > default.json

  1. Update projectId and bucket name

  2. Allow google-cloud

5- Update upload middleware configuration

path: src > services > [YOUR_SERVICE_NAME] > [YOUR_SERVICE_NAME].service.js

6- Update service validators

path: src > validators > [YOUR_SERVICE_NAME].validators.js

7- Update service hooks

path: src > services > [YOUR_SERVICE_NAME] > [YOUR_SERVICE_NAME].hooks.js

8 - Done!

test the service

test from dashboard : 1) open feathersjs-mongoose-casl-admin and try to upload a file

Last updated

Was this helpful?