Mirror

Vova Tkach bbd7bfc312 Create default config on install 6 years ago
assets aec7487514 Cleanup 6 years ago
consts d9fe05fa13 Prepare for version 1.0.3 6 years ago
cypress d9fe05fa13 Prepare for version 1.0.3 6 years ago
engine bc18acc8bc Display config errors in logs 6 years ago
hosts d4f8559de7 Blog pagination, settings, good pagination template 6 years ago
logger 3b45d1b86a Remove commented code 6 years ago
modules bbd7bfc312 Create default config on install 6 years ago
support d9fe05fa13 Prepare for version 1.0.3 6 years ago
utils d9fe05fa13 Prepare for version 1.0.3 6 years ago
vendor 04a925cc55 Upgrade bootstrap version 6 years ago
.gitignore d4f8559de7 Blog pagination, settings, good pagination template 6 years ago
Dockerfile d9fe05fa13 Prepare for version 1.0.3 6 years ago
LICENSE c391c57bd1 Update LICENSE 6 years ago
Makefile d9fe05fa13 Prepare for version 1.0.3 6 years ago
README.md d9fe05fa13 Prepare for version 1.0.3 6 years ago
cypress.json 6a9d57d4ae Cypress tests 6 years ago
go.mod 04a925cc55 Upgrade bootstrap version 6 years ago
go.sum 04a925cc55 Upgrade bootstrap version 6 years ago
main.go 110c02a93c Long play mysql connection, optimization 6 years ago
package.json 6a9d57d4ae Cypress tests 6 years ago
session.go ed9edb1bc4 Remove also session files at start 6 years ago

README.md

golang-fave

CMS written on Go with MySQL as database. Dynamical, splitted by modules, user friendly and thanks bootstrap is fully adaptive for mobile devices and tablets. All in one binary file, no need to install additional web servers. Go native templates with vars allow to do almost all what are need.

Usage

Usage of ./fave:
  -debug
    debug mode with ignoring log files
  -dir string
    virtual hosts directory
  -host string
    server host (default "0.0.0.0")
  -keepalive
    enable/disable server keep alive
  -port int
    server port (default 8080)

Hosts structure

hosts
├── localhost              # Main host directory
├──── config               # Config directory
├────── mysql.json         # MySQL config file
├──── htdocs               # Public http files
├──── logs                 # Logs dir
├────── access.log         # Access log file
├────── error.log          # Error log file
├──── template             # Engine templates
├────── 404.html           # Template for 404 page
├────── blog-category.html # Template for blog category
├────── blog-post.html     # Template for blog post
├────── blog.html          # Template for blog home page
├────── footer.html        # Footer
├────── header.html        # Header
├────── index.html         # Template for home page
├────── page.html          # Template for any other pages
├────── robots.txt         # Host robots.txt file
├────── scripts.js         # Theme scripts file
├────── sidebar-left.html  # Can be included in templates
├────── sidebar-right.html # Can be included in templates
├────── styles.css         # Theme styles file
└──── tmp                  # Temporary dir for session files

Unlimited hosts count. Template variables in Wiki or here and here.

Development

  • make - vet, test, build and run in debug mode locally
  • make build - build release for Linux, Mac OS X and Windows
  • make format - format all code by gofmt utility
  • make update - get all dependencies and put to vendor folder
  • make docker-test - build image and start on port 8080
  • make docker-img - build docker image only
  • make cy-dev - cypress tests in browser
  • make cy - cypress tests in console
  • make ab - http stress test