Skip to content

Fixing blog-post image rendering

Chris Walker requested to merge bitwrought-20230419-blog-preview-and-images into main

For staging builds, it looks like staging/ is prepended to links in at least some places . (You can inspect one of the broken image links at (https://dev.securityinabox.org/staging/en/blog/) to see an example.)

To support those link rewrites, I changed the teaser_image YML front-matter in blog posts to be, for example, media/en/blog/black-pegasus-wings.png rather than using a relative link like ../../../media/en/blog/black-pegasus-wings.png. (I tried /media/en/blog/black-pegasus-wings.png, as well, but it doesn't look like relative roots are supported in this context.)

I haven't tested it on /staging/ yet, but I would expect this new front-matter image link format to be more tolerant of the 'staging/' link prefix.

Merge request reports