/qorpress

A blog-engine example based on qor-sdk with dynamic front-end/back-end. [Help Wanted]

Primary LanguageGoMIT LicenseMIT

QorPress

QorPress is a blog engine based on the excellent Qor framework. It aims to be fast and dynamic.

If you encounter any issues or have any suggestions, please open a pull request :)

History

The idea came from the fact that we could not find a blog engine alternative with a back-end/front-end coupled at the same time. Hugo is designed for static website as we wanted something allowing to generate dynamic routes with a fast search engine.

Quick Start

You have basically 2 ways to test QorPress. The first one is to run/build it locally and you will have to install a mysql and a manticore server o your workstation. Either, you can use the docker-compose providing all the required services to run QorPress.

Local

dependency mode version
Go Local v1.13 (go modules)
Manticoresearch Local 3.3.0
MySQL Local 5.7
# Get QorPress
$ mkdir -p $GOPATH/src/github.com/qorpress
$ git clone --depth=1 --recursive https://github.com/qorpress/qorpress.git
$ cd qorpress

# Setup database
$ mysql -uroot -p
mysql> CREATE DATABASE qorpress;

# Start manticore
$ searchd --config ./.docker/manticore/manticore.conf

# Configure env variables (set the database parameters)
$ cd $GOPATH/src/github.com/qorpress/qorpress
$ mv .env-example .env

# Configure QorPress settings (set the db, ssl, smtp parameters)
$ cd $GOPATH/src/github.com/qorpress/qorpress
$ mv .config/qorpress-example.yml .config/qorpress.yml

# Run Application 
$ go run main.go --compile-templates
$ go run main.go

# Open Browser
$ open http://localhost:7000
$ open https//domain.com # if ssl enabled in qorpress.yml

Docker

The requirements are the following:

dependency mode version
Docker Docker v19.x
Docker-Compose Docker v1.24.x

If you don't have Docker/Docker-Compose check Setup Docker section

Setup Docker

Docker

macOS: https://docs.docker.com/docker-for-mac/install/

linux: https://docs.docker.com/install/linux/docker-ce/ubuntu/

Docker Compose

linux: https://docs.docker.com/compose/install/

# Get QorPress
$ mkdir -p $GOPATH/src/github.com/qorpress
$ git clone --depth=1 https://github.com/qorpress/qorpress.git
$ cd qorpress

# Run docker containers
$ docker-compose up --build

Generate plugins

$ cd $GOPATH/src/github.com/qorpress/qorpress
$ make plugins

# Run qorpress
$ go run main.go

Generate sample data

based on lorem ipsum texts and fake images

$ cd $GOPATH/src/github.com/qorpress/qorpress
$ go run cmd/lorem/*.go

or from kitploit website dump

$ cd $GOPATH/src/github.com/qorpress/qorpress
$ export GITHUB_TOKEN=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
$ go run cmd/kitploit/*.go

Run tests (Pending)

$ cd $GOPATH/src/github.com/qorpress/qorpress
$ go test $(go list ./... | grep -v /vendor/ | grep  -v /db/)

Admin Management Interface

QorPress Example admin configuration

RESTful API

QorPress Example API configuration

Online Example APIs:

Screenshots

Frontend

full post page

alt text

Backend

post manager

alt text

posts edition

alt text

categories manager

alt text

To do

  • add sitemap generator
  • add rss feed generator
  • implement caching system on api
  • implement caching system on html output
  • implement facteted search engine based on blevesearch
  • implement facteted search engine based on manticoresearch

License

Released under the MIT License.

@GORPRESS