Mirror

Vova Tkach ee1d2f4ded Upgrade bootstrap, optimization, mysql pool/logger correct shutdown, todo 5 years ago
assets fc2ab85cc3 Layout fixes, fix old price position 5 years ago
cblocks 77df7e3b99 Cache blocks, change code little 5 years ago
consts 77461241b6 Version++ 5 years ago
cypress 7cee97878d Fix blog Cypress tests 5 years ago
domains 287cfa76cf Feature/domain binding (#3) 6 years ago
engine ee1d2f4ded Upgrade bootstrap, optimization, mysql pool/logger correct shutdown, todo 5 years ago
hosts fc2ab85cc3 Layout fixes, fix old price position 5 years ago
logger c92dd376ff Write logs correctly to host dir when domain is attached 5 years ago
modules b75ca9c9c3 Shop, show colored promo price in list 5 years ago
support 5368a07cec Shop, promo price migration 5 years ago
utils a5eeb724ab Update mysql_struct_shop_product.go 5 years ago
vendor ee1d2f4ded Upgrade bootstrap, optimization, mysql pool/logger correct shutdown, todo 5 years ago
.gitignore 06bfeadabc Shop API, cache for products XML 5 years ago
Dockerfile 77461241b6 Version++ 5 years ago
LICENSE c391c57bd1 Update LICENSE 6 years ago
Makefile 77461241b6 Version++ 5 years ago
README.md d66cc66fb1 Update README.md 5 years ago
basket.go 03e1beae83 Shop basket, shop orders db migration, fix cypress reset action, optimization 5 years ago
benchmark.md 2ca50e38ae Benchmark data 5 years ago
cypress.json 3ecbf837d9 Cypress must always record video of tests 5 years ago
go.mod ee1d2f4ded Upgrade bootstrap, optimization, mysql pool/logger correct shutdown, todo 5 years ago
go.sum ee1d2f4ded Upgrade bootstrap, optimization, mysql pool/logger correct shutdown, todo 5 years ago
image.go 639a1f19f3 Don't block at startup 5 years ago
main.go ee1d2f4ded Upgrade bootstrap, optimization, mysql pool/logger correct shutdown, todo 5 years ago
package.json 4994cce25b Upgrade cypress 5 years ago
params.go ee1d2f4ded Upgrade bootstrap, optimization, mysql pool/logger correct shutdown, todo 5 years ago
session.go b69f242c00 Move products XML generation to background 5 years ago
smtp.go 0064385c1b Fix smtp server stuck of sending 5 years ago
xml.go 86fed836f8 Shop, add promo price to xml generation 5 years ago

README.md

Cypress

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
├────── .domains                   # Attached domains
├────── config.json                # CMS config file
├────── 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
├────── cached-block-1.html        # Cached block 1
├────── cached-block-2.html        # Cached block 2
├────── cached-block-3.html        # Cached block 3
├────── cached-block-4.html        # Cached block 4
├────── cached-block-5.html        # Cached block 5
├────── email-new-order-admin.html # New order email template
├────── email-new-order-user.html  # New order email template
├────── 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
├────── shop-category.html         # Template for shop category
├────── shop-product.html          # Template for shop product
├────── shop.html                  # Template for shop home page
├────── 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.
Docker image: https://hub.docker.com/r/vladimirok5959/fave

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 docker-push - build and push image to docker hub
  • make migrate - create new empty migration file
  • make cy-dev - cypress tests in browser
  • make cy - cypress tests in console
  • make ab - http stress test

Modules status

* Pages | ready for use | done 100%
* Blog  | ready for use | done 100%
* Shop  | ready for use | done 100%
* Files | in progress   | done 0%

Used resources