zonemaster-gui icon indicating copy to clipboard operation
zonemaster-gui copied to clipboard

Add gui server

Open hannaeko opened this issue 1 year ago • 7 comments

Purpose

Add a basic web server to serve GUI files.

Context

Based on #434 Following a discussion in the face to face, we decided to serve the GUI from a server to allow more flexibility.

Changes

  • [x] Add a server in perl (using Dancer2)
  • [x] Template index.html to include additional resources and override default ones (for css)
  • [x] Detect browser language using the server
  • [x] Add Makefile.PL for packaging
  • [ ] Update reverse proxy documentation
  • [ ] Update installation doc in zonemaster/zonemaster repo
  • [ ] Add service script to manage daemon
  • [x] Add example configuration and update configuration documentation
  • [ ] Remove unused files (configuration, scripts, ...)

How to test this PR

Running the server:

% plackup scripts/zonemaster-gui

hannaeko avatar Sep 07 '23 12:09 hannaeko

This is still a draft as it is not finished, but I would like some early feedback to avoid going the wrong path.

hannaeko avatar Oct 24 '23 10:10 hannaeko

Commit 80e36dd is the relevant stuff

hannaeko avatar Nov 02 '23 14:11 hannaeko

I still need architecture approval on this PR to finish (or change) this work.

hannaeko avatar Nov 13 '23 16:11 hannaeko

Danser will create daemon listening to http, won't it? Will that be on localhost using apache as a reverse proxy? Will everything still be packaged in one zip file as today?

matsduf avatar Dec 13 '23 13:12 matsduf

Dancer can spawn a small HTTP server for testing purposes, but when deploying a Dancer app in production, it can also spawn a FastCGI server, which is less expensive.

marc-vanderwal avatar Dec 13 '23 13:12 marc-vanderwal

Danser will create daemon listening to http, won't it? Will that be on localhost using apache as a reverse proxy?

yes, there will be a reverse proxy in front either way

Will everything still be packaged in one zip file as today?

No it will be packaged as a perl module.

hannaeko avatar Dec 13 '23 14:12 hannaeko

I am delaying that for next release, I think this PR needs more thoughts.

hannaeko avatar Dec 19 '23 10:12 hannaeko