1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Anuncie Aqui
    Anuncie aqui você Também: fdantas@4each.com.br

Set up static web app in Firebase App Hosting

Discussão em 'Angular' iniciado por amp, Julho 31, 2025.

  1. amp

    amp Guest

    I'm trying to set up a static server in my App Hosting backend for my Angular app (client-side rendering).

    For that, I'm following the instructions provided here and I am trying to use superstatic, as described in the article.

    However, it seems that no matter what I put in my package.json "start" script, I don't see any difference in the server being used. The responses of the requests to get the static files keep having the header "x-powered-by: Express", and all the other headers are exactly the same, even if I defined some in the superstatic.json configuration file.

    Also, in the Cloud Run Logs, I still see the log after each rollout:

    2025-07-30 20:41:26.633 BST Node Express server listening on http://localhost:8080


    Here is what I did so far:

    • installed superstatic 9.2.0 with npm install superstatic
    • added script "start": "superstatic dist/my-app --port $PORT --host 0.0.0.0 -c superstatic.json", to my package.json
    • created a superstatic.json with some headers configuration
    • pushed the code
    • created a rollout from that commit

    It seems that the npm "start" script is being ignored

    What could I be missing or how can I investigate the issue further?

    Continue reading...

Compartilhe esta Página