feat(ops/nixos/www): Serve rendered Tvix component SVG (hack!)

This is a quick hack to make it possible to view the rendered SVG on
https://code.tvl.fyi/about/tvix/docs/components.md

We want to be able to do this sort of thing dynamically in the future,
but we can't yet, so ... well. Deal with it.

Change-Id: Id2b819679d748b6f517018a9c6e72d5c1d806c4c
Reviewed-on: https://cl.tvl.fyi/c/depot/+/2743
Reviewed-by: flokli <flokli@flokli.de>
Tested-by: BuildkiteCI
This commit is contained in:
Vincent Ambo 2021-04-01 00:49:21 +02:00 committed by tazjin
parent 811fff2d8b
commit 53d8dd6a1e

View file

@ -12,6 +12,13 @@
forceSSL = true;
extraConfig = ''
# Serve the rendered Tvix component SVG.
#
# TODO(tazjin): Implement a way of serving this dynamically
location = /about/tvix/docs/component-flow.svg {
alias ${config.depot.tvix.docs.svg}/component-flow.svg;
}
# Static assets must always hit the root.
location ~ ^/(favicon\.ico|cgit\.(css|png))$ {
proxy_pass http://localhost:2448;