Skip to content

CMS for creating personal websites for the IndieWeb, powered by DuckDB and JSON

License

Notifications You must be signed in to change notification settings

cleverdevil/dwell

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dwell: An IndieWeb CMS for Personal Websites

Dwell is a simple CMS for creating your own indieweb website, including support for micropub, indieauth, and webmention. Dwell was created to power the personal site of cleverdevil, which currently runs the known content management system. Under the hood, Dwell is built in the python programming language, and uses duckdb for its query engine, though all content is stored on-disk as JSON files contained within a hive partitioned directory structure.

Why?

For many years, I have had my own site. In fact, my current website includes a massive archive all of my content starting from 2002! I have even migrated all of the content I posted on Instagram, Twitter, and Facebook before I left those silos entirely after they became cesspools of misinformation and surveillance capitalism owned and operated by billionaires with values that do not align with my own.

My current site runs on known, which has served me well. While I am able to write PHP, it is absolutely not my language of choice or expertise. In addition, I would like to make my site more lightweight, with as few dependencies as possible, and no need for complex relational databases.

Why not use something like WordPress? Yes, WordPress has the benefit of a massive community, but is essentially a giant pile of legacy. I have a lot of experience with that community, and I think its lovely, but isn’t really focused on what I care about, and has all of the same complexity issues as Known, with the downside of being an absolute security nightmare.

Why not a static site generator? I considered it, but I like the ability to create extremely dynamic pages. With DuckDB, I get all of the benefits of a relational database with none of the operational pain.

Lastly, because its fun. I love working on my site!

Technical Details

Content is stored on disk as JSON files in a directory structure that is partitioned based upon date, as follows:

content/
    year=2023/
        month=11/
            day=12/
                post-uuid.json

Dwell uses the aforementioned DuckDB to make the entire content directory queryable with SQL, without the need to run a separate, heavyweight database server. Very large sites with tens of thousands of posts can be completely indexed by Dwell in a matter of a few seconds. The complete content is stored in a table called raw_content within the content.db database, and a convenience view called content is created which makes the data easier to interact with.

Status

This is early. Very early. The first focus has been proving out the data storage, indexing, and querying mechanism using DuckDB. Below is a list (that is likely incomplete) of features, including what is done, and what is in-progress.

  • Consume and index a hive-partitioned directory of MF2 JSON
  • Storage and index support for post kinds
    • Blog
    • Status
    • Bookmark
    • Watch
    • Play
    • Reply
    • Photo
    • Checkin
    • Listen
    • Recipe
    • Review
    • RSVP
  • Query for posts
    • Get by post id
    • Query by date range and post kind
    • Ordering, limit, and offset
  • Micropub support
    • Create content
      • MF2 JSON
      • Form encoded
      • Multipart form
    • Update content
    • Delete content
    • Undelete content
    • Media endpoint
    • Syndication
      • Mastodon
      • Bluesky
  • IndieAuth support
    • Token database
    • Password configuration
    • Micropub endpoint enforcement
    • User-facing auth flow
    • User-facing auth flow beautification
    • Separate IndieAuth code
  • Webmention
  • Move all post kinds to plugins, other than Blog, Status, and Photo
  • Website views
    • Home stream
    • Custom streams
    • Monthly summaries
    • On this day
    • Photos page
    • Static pages
    • Profile
    • Archive
    • Now
    • Overview
    • Make all streams and post kinds use proper microformats
  • Forms for authenticated users to create all “kinds” of content
  • Fixing ingestion for specific types and content that is missed
    • Recipe
    • Like / Repost kind
    • Interactions (likes, primarily)

At first, I will entirely focus on getting my own website fully functional on-top of Dwell, to enable me to migrate off of Known, but I am actively seeking collaborators that are interested in a shared codebase for building our own sites.

About

CMS for creating personal websites for the IndieWeb, powered by DuckDB and JSON

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published