Dokku is pretty cool, but my main issue with it is that it doesn’t support multiple nodes or something like docker swarm (or k8s). So, you’re basically putting all of your eggs in one basket.
1. The response instance variable looks to be nil in the snippet which is why you probably cannot link to the response show page.
2. When are you trying to make the differentiation? Is it when pulling up a list of available questionnaires to take? If so, you could have an attribute on the questionnaire for the type of user. Something like "responder_type" and make it an enum. When listing out the questionnaires, you could query on this attribute depending on the actor (a lecturer or student).