A Go/Beego project used as a starting point for web applications.
The main goal is to use a JavaScript framework to implement application's views,
with as few as possible server rendered templates from views
directory.
If you want to work with Beego's server side static templates,
just remove the client
directory and modify the index.html
template.
- WebSocket integration with
- basic models for websocket clients (client, room, pool of rooms)
- WebSocket React component
- Configuration files for Nginx, SupervisorD and SystemD for *nix systems
- Check
localhost:8080/api/v1/websocket
simple API setup returning number of connected websocket clients and rooms - React ready
- Email sending with or without templates
- REST API ready
- JWT Token generation ready
- Session ready for classic login/logout handling
- User model to start with
- Login rate limiter for failed logins protection
- API rate limiting
- clone this repository to a different directory, for example:
git clone https://github.com/stef-k/gosimple.git myproject
- run the
makemine.sh
script (it will remove the.git
directory and rename all references of Go Simple to myproject) - on one terminal tab start the server
bee run
- if you want to use the React frontend starter cd into
client
dir andnpm install
- start webpack and gulp watchers with
npm run alldev
Webpack watcher outputs the bundle.js
file to static/js/
directory.
Gulp watcher outpus style.css
style.min.css
and style.css.min.map
to static/css
directory.
- changed
controllers/default.go
tobasic.go
- changed
routers/router.go
, now contains only package's init function setting up routes - in models directory there are
client.go
,message.go
,room.go
andpool.go
related to WebSocket integration deployment
directory containing configuration files for web server, systemd, etc
- development - production configuration files for the frontend
DISTRIB_RELEASE=16.04
DISTRIB_CODENAME=xenial
DISTRIB_DESCRIPTION="Ubuntu 16.04.1 LTS"
| ___ \
| |_/ / ___ ___
| ___ \ / _ \ / _ \
| |_/ /| __/| __/
\____/ \___| \___| v1.5.1
├── Beego : 1.7.0
├── GoVersion : go1.7