A blog software. It's meant to be as minimal as possible (thin client), while still maintaining basic readability and styling.
Find a file
2020-11-22 00:07:05 +01:00
content Added request logging 2020-11-21 23:45:59 +01:00
site fixed static path handling and deleted html.rs 2020-11-22 00:07:05 +01:00
.gitignore added images to gitignore 2020-11-21 22:38:39 +01:00
docker-compose.yml should it die, we want it to restart 2020-11-17 18:05:49 +01:00
Dockerfile Dockerization and generalization of the project. Make it accessable for everyone 2020-11-17 18:01:54 +01:00
README.md updated readme for social buttons 2020-11-21 22:49:12 +01:00

Crablog

Pure rust. Built with actix, diesel, tera, serde and sqlite3.

Build instructions using docker

  1. Clone the repository
git clone https://github.com/leonardlorenz/crablog
cd crablog
  1. Set up your configuration file (see below)
  2. Build and run the docker container (Will compile from source and thus take a while)
docker-compose up -d

Configuration environment file

All configuration options are defined in .env, to be created in the same directory as this readme.

An example configuration:

USERNAME=yourusername
EMAIL=me@mydomain.tld
BIND_PORT=8000
SUBMIT_TOKEN=Submit!123 # token needed for submitting
GITHUB_ACCOUNT=usernam3
TWITTER_ACCOUNT=usernam3
MASTODON_ACCOUNT=usernam3@mastodon.social
REDDIT_ACCOUNT=usernam3
DISCORD_ACCOUNT=usernam3

# only needed when not using a docker container
ROOT_PATH=/path/to/template/directory/and/sqliteDB

Routes

  • / site welcome
  • /blog shows the last 5 posts
  • /blog/id/ shows a single post by id
  • /blog/all shows all posts
  • /blog/submit set your submit token and create posts
  • /blog/edit/ edit, delete or hide posts

API Routes

  • /api/blog/posts returns all posts as json