lalalilo / aws-spa

A no-brainer script to deploy a single page app on AWS
42 stars 3 forks source link

[Feature request] Allow specification of `DefaultRootObject` when creating/updating cloudfront distribution #57

Open iamogbz opened 8 months ago

iamogbz commented 8 months ago

Specific use-case is deploying multiple versions of the app based on the the current git branch, as highlighted by the docs.

You can also specify a path: app.example.com/something. This can be useful to deploy multiple versions of an app in the same s3 bucket. For example one could deploy a feature branch of the SPA like this:

While it is possible to remove the branch name from app.example.com/<branch>, it would be helpful to allow configuring the default root object served when no branch path is given.

Example: Deploying and having the default release branch be main;

Open to putting up a PR for the changes needed