News for hackers. Stuff that matters.
Re:Show HN: We built a FOSS documentation CMS with a pretty GUI by oneseven on Thursday September 05, 2024 @03:10PM (#41459580)
Looks great! Why do you need a database? Seems like that limits the deployment options. You can't deploy to github pages, for example.
Re:Show HN: We built a FOSS documentation CMS with a pretty GUI by corytheboyd on Thursday September 05, 2024 @03:58PM (#41459932)
You must be conflating CMS and SSG. A CMS is basically GUI-for-database on the admin side, and content is generated on-demand from database content. The served content is effectively “static” until something in the database changes (and could be cached appropriately), but it’s quite different than SSG.
Re:Show HN: We built a FOSS documentation CMS with a pretty GUI by arch1e on Thursday September 05, 2024 @03:13PM (#41459601)
Good point! We use a database (SQLite or Postgres) to enable more advanced features like versioning, collaboration, and access control, which aren't easily managed with static files alone. The database also allows us to scale better for teams with frequent updates.

While it does limit deployment to platforms like GitHub Pages, Kalmia is designed for teams that need more than just static documentation—think of it as a middle ground between static site generators and fully dynamic CMS solutions. For purely static sites, there are other great options out there, but Kalmia focuses on more interactive, collaborative documentation.

That said, we’re actually interested in providing an option for users to export and deploy it to platforms like GitHub Pages or similar, so stay tuned for future updates on that!

Re:Show HN: We built a FOSS documentation CMS with a pretty GUI by 9dev on Friday September 06, 2024 @02:03AM (#41463300)
You could look into frontmatter to store metadata within the files, and just load it all into memory on startup. Even for huge projects, that probably won’t hurt anyway.
Re:Show HN: We built a FOSS documentation CMS with a pretty GUI by arch1e on Friday September 06, 2024 @10:19AM (#41466480)
We already load all the documentation assets into memory whenever something changes. Even with large projects spanning hundreds of pages and page groups, it remains very fast—under 1 second in our testing.

That being said, there are some cases where a database is necessary. For example, handling multiple people editing the same document simultaneously wouldn’t work well with just flat files. Also, where would we store user emails/passwords for authentication? Another feature Kalmia supports is private documentation, where users need to log in to access certain docs (there's a simple toggle to enable authentication).

That said, adding an "export to zip" or "push to git" button is totally feasible, and it's something we've had a lot of requests for. While we don't personally use it, we'll be adding it so people can host their docs on static file platforms without needing Kalmia as the backend.

Re:Show HN: We built a FOSS documentation CMS with a pretty GUI by 9dev on Saturday September 07, 2024 @06:52AM (#41473104)
The nice thing about flat files represented in memory would really be maximum performance, no external data store necessary, and easy portability. I definitely understand that sorting out concurrency by using a DBMS is easier, however.

> Also, where would we store user emails/passwords for authentication?

For this kind of application, I’d strongly recommend (and request from anything I buy) OAuth signin via my existing identity provider. That means I don’t have yet another location for accounts, and you don’t have to worry about storing them securely.