View Categories

GCP Static Pages

< 1 min read

You can host static web content on Google Cloud Platform using a storage bucket.

https://stackoverflow.com/questions/38053113/deploying-angular2-web-app-on-google-cloud-buckets

You’ll need a CNAME DNS entry for the location of the bucket and the bucket must be named with the same name. For example, if you want to host content at projects.shawnweaver.com, you’ll need a bucket named “projects.shawnweaver.com”.

To get pages to show up properly, you’ll also need to set the default pages using the “Edit website configuration” option in the tools button at the right side of the bucket, and set the default page as index.html (or whatever else you want it to be). Setting the 404 page to the same can help with some web app issues as described here: https://stackoverflow.com/questions/38053113/deploying-angular2-web-app-on-google-cloud-buckets

Powered by BetterDocs