feat: add docker container.#73
Conversation
3d057ca to
a4561cf
Compare
Vite's asset `base`, the router's basename, Docker's nginx rewrite/<base> tag, and the GitHub Pages 404 redirect were each configured through overlapping, duplicated vars (VITE_BASE_URL, VITE_PATH_PREFIX, a hardcoded vite.config.mts base, and a hardcoded 404.html segment count) that had to be kept in sync by hand and didn't actually agree with each other — building with a path prefix and serving the result locally didn't work. VITE_BASE_URL (BASE_URL in Docker) is now the single source of truth; everything else derives from it. Also replaces Docker's separate config.js file with an inline <!-- __APP_CONFIG__ --> splice directly into index.html.
9c438ab to
aa51644
Compare
|
@pantierra Tweaked some things which I pushed directly here. There were several places where the url was needed and there were multiple configurations. The vite config's base was set to There were also different variables for the base url and the prefix. I figure they could be merged - we provide the full url which is needed for the app, might as well extract the prefix from it. Please have a look and let me think if you agree with the changes. |
|
I agree with your take. Looks good to me. This fixes a bug, is much easier and streamlined and the Docker flexibility is there. |
Related EOEPCA/data-access#220