Skip to content

Fix Frontend NextJS deployment #8

@dmitri-mcguckin

Description

@dmitri-mcguckin

After some dinking around with the frontend I've come to understand why embedding the environment variables into the NextJS app is necessary (for now).

This is because NextJS builds a static set of JS pages and then serves those to the end-user (web browser).

At-present, the pages are served via yarn. This is technically incorrect to package and serve content this way as yarn is just a dev tool with many dev hooks and handles embedded in the content for debugging.

Instead, we should be using a WSGI library to have the "back" of the frontend serving via our own minimized WSGI code. With this, we should be able to pull any environment variables we need and adjust the content that gets served (content with calls to the api url) and be able to properly and dynamically serve the right content.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions