For my projects with YNH I am searching for a good way to document everything I do. The last few months I have become a big fan of MKdocs. and other static site generators such as Jekyll, Hugo etc.
I am now looking for a way to use one of these with YNH, but can’t really find a nice workflow.
For now I have this:
- a local directory containing all .md files, images and such
- sync this directory using Nextcloud so other can modify the same files.
Now the last step would be; have some app/script that creates a static site from these files. Ideally hosted on YNH.
I hope this is clear, if not, let me know. Already thnx for any tips!
Je ne sais si j’ai bien compris.
Sinon, je verrai bien :
- créer le site statique avec Hugo,
- le publier avec Custom Webapp sous Yunohost.
EDIT: English Version
Oh, sorry, a deepl translation
I don’t know if I understood correctly.
If not, I’ll see:
- create the static site with Hugo,
- publish it with Custom Webapp under Yunohost.
Hi @Melina, this thread’s language has been set to English. Please alter your message and use this language. You can check out this discussion: The language barrier.
I have never done anything like that, but let’s see…
- Right now, there is no MKdocs app for YunoHost. But it looks simple enough that you can install it locally, run its web server and use a Redirect app to proxy its web server to YunoHost.
- Regarding making the files available to Nextcloud:
- I guess you can allow the
nextcloud user to access MKdocs’ files* and create a local external storage within Nextcloud to have it displayed in there?
- Or keep doing what you are doing and use a symbolic link (as long as MKdocs’ user has read access to source files, I guess it should work?)
- Regarding triggering the build:
- You can have a look the Nextcloud Flow, which can trigger a script whenever you want or based on some events (like a file being saved in MKdocs’ directory)
- You can run MKdocs’ server in dev mode, it will trigger a build whenever a file is altered.
usermod nextcloud -aG mkdoc (with
mkdoc the user running the webserver and owning the files). You may need to restart Nextcloud (
systemctl restart php7.3-fpm)
@tituspijean thnx for your answer! There are a few steps in there that are a bit more technical then my level of expertise. But they’ll make a nice challenge.
Do not hesitate to ask for clarification and support.
will do! I highly appreciate your ton of help around the forum here and how you seem to try to help everyone here
I am looking for a way to write and share documents (easily).
Bookstack ok for snippets, image editor link, but not for the documentation structure (at the top): shelves, books, chapters…
Gitbook (on YNH) very interesting for the free book structure on the left menu and PR on github. But few tools: no snippet, no image editor link! And no choice for your hosting :).
Note that Grav (on YNH + YNH website) is a little bit to complicated for me
Right now, I am trying Hugo as a Webapps (thank you for having shared this solution here).
And I will be using Hugo Book Theme: https://hugo-book.netlify.app/
Make you know more later… Stay tune
In conclusion, just to tell you I am interested in your MkDocs experience on YNH
Nice August 2021 vacation
From Andernos-les-bains, France. José
Good things take time. I guess
I finally found time (and a need) to return to this topic.
@jrd10 how did your experiments end? Did you build a working site?
As for @tituspijean; I am still unsure about many of the things you suggest:
This will break make my website inaccessible when I close my laptop, or move to another IP address… right? (that is not necessarily a bad thing btw…). Also, I could add a DNS redirect directly at my hosting provider… and skip YNH altogether? (this is how I solved it for now…)
I meant it differently; the .md files I make are already synced to my YNH server (and other clients) using Nextcloud. I was wondering if, because they are already there; there could be a way for the server to grab them and turn them into a website.
whoa, this is getting a little outside my comfort zone; will have a look at it, but hard to imagine so far what it means and would do
can you use Gitbook with a local repository of markdown files?
Hummm! I am not sure
You can publish and host books easily online using gitbook.com.
In fact, I used https://app.gitbook.com
oh my! no no no; you are out.