azimuth icon indicating copy to clipboard operation
azimuth copied to clipboard

Create a production image for the front-end (nginx)

Open gabegma opened this issue 3 years ago • 2 comments

gabegma avatar Jul 25 '22 19:07 gabegma

@christyler3030 I'm not an expert on NGINX, do you have some pointers?

I'm not sure how our users will be able to enter "their own" backend. Assuming a proxy file:

# nginx/proxy.conf
local localhost:8091

Do we ask our users to modify this file? Do we have an env-var that creates the mapping before starting nginx? What were you thinking?

Dref360 avatar Aug 04 '22 15:08 Dref360

From our discussions, we are trying to solve two problems:

  1. Map resources (Ex: local => http://localhost:8091, remote => mycoolbackend.com)
  2. Use NGINX to handle HTTPS, malformed requests, probing attack etc.

What would be ideal would be:

  1. Continue to develop server.js so that we can do the resource mapping there.
  2. Setup very small nginx proxy that redirects all traffic to this small backend.

To me, the latter is less important and we should prioritize 1, which would enable users to run Azimuth on the Cloud, on a K8 server while hosting the frontend locally or somewhere else entirely.

Thoughts?

Dref360 avatar Aug 10 '22 23:08 Dref360