mozilla / webcompat-dashboard

Web Compatibility Knowledge Base Next Generation Dashboard
Mozilla Public License 2.0
2 stars 2 forks source link

Issue #14 - Don't use `ViteExpress` in production. #15

Closed denschub closed 6 months ago

denschub commented 6 months ago

This was a bit of an oversight on my end. The container image already builds the frontend assets into dist/:

https://github.com/mozilla/webcompat-dashboard/blob/ee42d5e3601a9570d09fc976ccc8c2e4c8c9dee8/Dockerfile#L20-L21

but we're still using ViteExpress in production. This has a huge memory cost (see #14), and there is no reason to do that. The container images command is calling npm start, so we're always have the NODE_ENV var set correctly in prod:

https://github.com/mozilla/webcompat-dashboard/blob/ee42d5e3601a9570d09fc976ccc8c2e4c8c9dee8/package.json#L11

so this is an easy fix that requires no other changes. This closes #14.

r? @ksy36 fyi! @moztcampbell