Configure asciidoc includes to really include the referred adocs
In advance
I found already issue https://github.com/gollum/gollum/issues/878 . The mentioned solution(s) did not work. My config.rb is loaded and other configs take effect.
Describe the bug
I'm using the gollum docker image 6.1.0 in read only mode to serve documentation from different repos, like gitlab wikis and asciidoc documentations. Most of the asciidoc files use asciidoc include:: to embed other adocs.
Viewing such an adoc with includes lead to a list of links which I can follow successfully - but I like the content of the included adoc to be embedded.
I've been informed about asciidoctors safe mode and think it's the reason for this behaviour. I made several attempts to set the safe mode to "unsafe" (yes due to missing documentation and knowledge about ruby I bothered chatbots...) and followed the snippets in the referenced issue.
My tries to configure the safe mode via the config.rb failed without any change of behaviour. The snippet in the referenced issue led to a changed safe mode but did not render the included adoc.
What is the preferred way to configure gollum to embed asciidoc includes?
To Reproduce Steps to reproduce the behavior:
- paste the snipped of https://github.com/gollum/gollum/issues/878#issuecomment-605699589 in a config.rb
- prepare a git repo with an adoc which includes another adoc
- test with an asciidoctor call the correctness of the adoc
- run gollum with the prepared git repo, for example like I do by:
docker run --rm -p 4567:4567 -v $(pwd):/wiki gollumwiki/gollum:6.1 --no-edit --emoji --lenient-tag -lookup --config config.rb - navigate via "Overview" Button to the adoc
Screenshots
Expected behavior The adoc is rendered with the embedded other adoc like done by asciidoctor
Environment Info
Always include the output of the gollum --versions command (NB: versions in plural).
docker run --rm -p 4567:4567 -v $(pwd):/wiki gollumwiki/gollum:6.1 --no-edit --emoji --lenient-tag
-lookup --config config.rb --versions
The /wiki directory exists and is writable.
DEPRECATION WARNING: --lenient-tag-lookup. This switch will be removed in the future. You will still be able to set the option via config.rb.
Gollum 6.1.0
Running on: x86_64-linux-musl with Ruby version 3.3.6
Using:
rugged 1.7.2
gollum-rugged_adapter 3.0
gollum-lib 6.0
Markdown rendering gem: kramdown
Other rendering gems:
RedCloth 4.3.4
org-ruby 0.9.12
creole 0.5.0
asciidoctor 2.0.23
wikicloth 0.8.3Source: gollum/gollum