I realised that you need to embed the post_url variable in a markdown link like so [guidelines]({% post_url 2021-11-09-course-info %}) for it to render as a link.
Removed headers which duplicated the title in the front_matter
---
layout: post
title: "Structuring a lecture for new courses"
date: 2021-11-17 10:30:00 +0200
categories: knowledge
tags: teaching
---
post_url variable
in a markdown link like so[guidelines]({% post_url 2021-11-09-course-info %})
for it to render as a link.