MongoDB.live, free & fully virtual. June 9th - 10th. Register Now MongoDB.live, free & fully virtual. June 9th - 10th. Register Now

Autodeploy to stitch

Hello. I’m setting up auto deployment to stitch and it looks like to enable this need to be in the files/ folder and not in any subfolders.

├── hosting/
│ ├── metadata.json
│ └── files/
│ └──

see…
https://docs.mongodb.com/stitch/deploy/application-schema/

Does anyone know a way around this as it’s not a very good way to organise the project files.

Hi @Daniel_Gold,
Welcome to the forum!

Currently this is the structure that is needed for Stitch applications format. The configuration files are grouped into directories based on their component type, in your example that would be for MongoDB Stitch Hosting.

Could you elaborate further what do you mean by this ? You can create sub-directories under the hosting/files directory, i.e:

├── hosting
│   ├── files
│   │   ├── index.html
│   │   ├── x
│   │   │   └── foobar.html
│   │   └── y
│   │   └── baz.js
│   └── metadata.json

Or are you referring to the Stitch app itself to be a sub-directory of a Git repository ? If so, there’s an open canny request for this Stitch: GitHub automatic deploy from a subdirectory, feel free to upvote or comment the request.

Regards,
Wan.

1 Like