inuitviking / imms
Fully automatic SSG. Host this somewhere, forget about it, have your static content up to date, always.
Requires
- php: ^8.3
- ext-curl: *
- ext-dom: *
- composer/composer: @dev
- czproject/git-php: ^4.2
- elgigi/commonmark-emoji: ^2.0
- inuitviking/imms-dark: ^1.1.0
- jnjxp/commonmark-wikilinks: ^0.1.2
- league/commonmark: ^2.2
- league/container: ^4.2
- league/flysystem: ^3.0
- league/plates: ^3.5
- monolog/monolog: ^2.9.3
- n0sz/commonmark-marker-extension: ^1.0
- psr/log: 2.0.0
- scssphp/scssphp: ^1.10
- simonvomeyser/commonmark-ext-lazy-image: ^2.0
- sven/commonmark-image-media-queries: ^1.0
- thadbryson/flysystem-sync: ^3.0
- ueberdosis/commonmark-hint-extension: ^0.1.0
- zoon/commonmark-ext-youtube-iframe: ^2.0
- dev-master
- 2024.05.07.26
- 2024.05.07.25
- 2024.05.07.24
- 2024.05.07.23
- 2024.05.07.22
- 2024.05.07.21
- 2024.05.07.20
- 2024.05.07.19
- 2024.05.07.18
- 2024.05.07.17
- 2024.05.07.16
- 2024.05.07.15
- 2024.05.07.14
- 2024.05.07.13
- 2024.05.07.12
- 2024.05.07.11
- 2024.05.07.10
- 2024.05.07.9
- 2024.05.07.8
- 2024.05.07.7
- 2024.05.07.6
- 2024.05.07.5
- 2024.05.07.04
- 2024.05.07.3
- 2024.05.07.2
- 2024.05.07.1
- 2024.05.07
- 2024.03.22.3
- 2024.03.22.2
- 2024.03.22.1
- 2024.03.22.0
- 2024.02.26.6
- 2024.02.26.0
- 2024.02.14.8-rc5
- 2024.02.14.8-rc4
- 2024.02.14.8-rc3
- 2024.02.14.8-rc2
- 2024.02.14.8-rc1
- 2024.02.14.7
- 2024.02.14.6
- 2024.02.14.5
- 2024.02.14.4
- 2024.02.14.3
- 2024.02.14.2
- 2024.02.14.1
- v2024.02.14.0
- v2023.01.14.0
- 2022.04.12.6
- 2022.04.12.5
- 2022.04.12.4
- 2022.04.12.3
- 2022.04.12.2
- 2022.04.12.1
- 2022.04.12
- dev-dev
This package is auto-updated.
Last update: 2025-02-25 14:53:57 UTC
README
IMMS is a kind of SSG (Static Site Generator), but without you having to build it yourself and entirely without pipelines.
It takes your Markdown and renders it as HTML in a file cache, and serves this HTML without having to re-render it again. This makes IMMS pretty fast at serving content.
If you have HTML files instead of Markdown files, it will simply stitch the HTML content together with overall template files, and cache the final result. Again, making IMMS pretty fast at serving content.
If you need help or want to learn more, please check out the wiki.
Intended use cases
- To serve a repository with markdown or HTML files (such as a GitHub/GitLab wiki!)
- To serve as an SFTP server for your old pals to host their static HTML (docker image supports this out of the box!)
- Other semi- to fully static content
There's quite literally no fuss (or very little of it):
- No database
- No users that need to log in
- No need for manual cache handling
- No built-in editors
Features
- GitHub Flavoured Markdown
- This is just the base; it should have almost full support for Gitlab Flavoured Markdown as well
- Header Permalinks
- Syntax highlighting for code blocks
- Hints
- Text Highlighting (Remember those yellow highlighters?)
- Youtube iframes
- Emojis
- Image attributes (size them however you want!)
- WikiLinks
- Sub pages
- Create a directory with the same name of a markdown file
- Add markdown files into the directory
- IMMS will link the markdown file and directory together automatically.
- Support for special characters in markdown file name
- Table of Contents (configurable!)
- Automatic caching (and clearing of it!)
- A (albeit quite simple) CLI tool
- Lazy image loading
- Integrated git (this feature must be enabled in config)
- You can feed it HTML or Markdown; doesn't matter, it will handle it.
- Custom templates (using Plates!)
- Custom plugins!
Additional features in Docker
- Makes use of PHP's opcache to improve performance
- Makes use of Apache's built-in caching, to serve files even faster
Getting started
Docker Compose
An example could be like so:
services:
imms:
image: registry.gitlab.com/inuitviking/imms:latest
ports:
- 8080:80
- 2222:2222
# expose:
# - 1234
# - 2222
environment:
- APACHE_PORT=1234
- APACHE_CACHE_AGE=900
- APACHE_CACHE_SIZE=5M
- SSH_PORT=2222
- SSH_USER=imms
- SSH_PASS=imms
volumes:
- ./.docker/documents:/var/www/src/documents
- ./.docker/config:/var/www/config
./.docker/documents
: The place where you store your uploads and markdown files../.docker/config
: This is where theconfig.ini
file is stored
All of the above is supplied in .docker
as examples.
You may also see the Apache config and PHP config within .docker
; this is used for building the docker image, to configure opcache and Apache's built-in cache.
The docker image provided makes use of opcache and Apache's included caching system to improve response time.
If you prefer to use the built-in git, you can omit the "documents" volume, as IMMS would then handle the pulling internally.
On a good ol' web server
composer create-project inuitviking/imms
cd imms
Once created, you can configure it to pull HTML/Markdown from a remote repository in config/config.ini
.
If you prefer not to do that, make sure to create the necessary directories:
mkdir -p src/documents
touch src/documents/index.md
You may want to take a look at config/config.ini
to adjust to your liking.
Dependencies
Composer dependencies:
- league/commonmark
- league/plates
- scssphp/scssphp
- ueberdosis/commonmark-hint-extension
- zoon/commonmark-ext-youtube-iframe
- elgigi/commonmark-emoji
- n0sz/commonmark-marker-extension
- sven/commonmark-image-media-queries
- jnjxp/commonmark-wikilinks
- simonvomeyser/commonmark-ext-lazy-image
- league/plates
- czproject/git-php
- league/flysystem
- thadbryson/flysystem-sync
PHP dependencies
- PHP8.3 or newer
- ext-dom
Server dependencies