SoftInstigate / restheart

Rapid API Development with MongoDB
https://restheart.org
GNU Affero General Public License v3.0
805 stars 171 forks source link

mongo-mounts not working as expected #367

Closed shireefadel closed 4 years ago

shireefadel commented 4 years ago

I Needed to change the URI , instead of exposing my database name using an alias name, but I couldn't use this alias name.

Expected Behavior

 Instead of requesting my resources like this 

http://domainname/databasename/collectionname use this alias http://domainname/resources/collectionname

Current Behavior

when accessing this url http://domainname/resources/collectionname I got the message {"http status code":404,"http status description":"Not Found","message":"Collection 'resources' does not exist"} but this url works http://domainname/collectionname

Steps to Reproduce

  1. In .properties file configure this root-mongo-resource = /databasename
  2. In your restheart-platform-core.yml configure this mongo-mounts: - what: {{{root-mongo-resource}}} where: /resources
  3. try to access your mounted resource like this http://domainname/resources/collectionname

Possible Implementation

ujibang commented 4 years ago

Cannot reproduce. Suspect a misconfiguration, checking with @shireefadel

ujibang commented 4 years ago

due to wrong configuration, helped @shireefadel checking conf files