Flarum 0x
Customized flarum for the 0xFFFF Community.
We are working on:
- Customisation based on the 0xFFFF Community needs.
- A modern, cloud-based Flarum Development & Deployment workflow.
- Encourage more people to participate and contribute to the Flarum Community.
Customizations
The customizations of Flarum 0x consists of these parts:
- Initialized Flarum Skeleton with our custom
composer.json
/ composer.lock
config (contains the extensions we are using).
- Patches for the extensions in
vendor/
to make some small changes without publishing new Composer Packages (see patches/README.md).
- Custom flarum extenders in
extend.php
.
- Custom third party extension integrated into this repo as submodules.
The features we have customised include:
- Support global assets CDN config.
- Save avatars to S3-compatible Storage instead of local disk (thanks to askvortsov1/flarum-azure-poc).
- Add support for blomstra/flarum-redis extension (for Queue / Cache / Session), enable the Queue Worker to consume the Background Tasks asynchronously.
- Add support for custom head HTML like add some
<script>
/ <link>
/ <meta>
tags in config.php
.
- Replace some hard-coded JsDelivr resource URLs with ByteDance's cdn (for mainland China users).
- All the extensions required at
composer.json
- ...
Local Development Env Setup
We are using Development Containers with our LNMP config to save the time required to configure the environment.
Steps to configure your local development environment:
- Install Docker (Docker Desktop / Docker CE / OrbStack, etc...) on your dev machine.
- Install VSCode and Dev Containers VSCode extension.
- Just clone this repository and use VSCode open it, then VSCode would notify you to open the repository in the Dev Container.
- After the Dev Container has initialised, open
http://localhost:8080
and see your Flarum app instance (It will automatically forward the ports to local).
Or you can just create a new GitHub codespace with this repo, then start development.
Production Deployment
Basically running a Flarum 0x website requires two Docker container instances.
- Flarum 0x, latest pre-built image:
ghcr.io/0xffff-one/flarum-0x:latest
.
- A MySQL-compatible DBMS, MySQL, MariaDB or other, use MySQL with ngram support for CJK full-text search.
You can deploy them via Docker Compose.
Contribution
Any contributions are welcome. Please feel free to:
- Open an Issue
- Create a Pull Request
- Comment in an Issue / PR / commit
- Open a Discussion in 0xFFFF Forum / Discord / QQ Group
Thank you for willing to contribute to this project!
TODO
- [x] new Dev Envionment setup config
- [x] build process for Front-end Patching
- [x] Update latest README.md about Dev Env setup and Production deployment
- [x] Optimize the production Docker image config
Contributors
This project exists thanks to all the people who contribute.
Reference
License
Flarum is open-source software licensed under the MIT License.