Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/linlindu/messageboard
a restful messageboard api
https://github.com/linlindu/messageboard
api gin golang graceful-shutdown jwt restful
Last synced: about 2 hours ago
JSON representation
a restful messageboard api
- Host: GitHub
- URL: https://github.com/linlindu/messageboard
- Owner: LinlinDu
- License: apache-2.0
- Created: 2019-06-23T14:04:44.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2019-06-25T06:21:26.000Z (over 5 years ago)
- Last Synced: 2024-06-19T16:43:37.852Z (5 months ago)
- Topics: api, gin, golang, graceful-shutdown, jwt, restful
- Language: Go
- Homepage:
- Size: 20.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# messageboard
a restful messageboard api## installation
```
$go get github.com/LinlinDu/messageBoard
```## How to run
### Required
- Mysql
### Ready
Create a **message_board database** and import [SQL](https://github.com/LinlinDu/messageBoard/blob/master/docs/message_board.sql)
### Conf
You should modify `conf/app.ini`
```
#debug or release
RunMode = release[app]
JWTSecret = 23347$040412ImagePrefixUrl = http://127.0.0.1:8000/
ImageSavePath = runtime/upload/images/
# MB
ImageMaxSize = 5
ImageAllowExts = .jpg,.jpeg,.pngLogSavePath = runtime/logs/
LogFileExt = log
TimeFormat = 20060102[server]
HTTPPort = 8000
ReadTimeout = 60
WriteTimeout = 60
...
```### Run
```
$cd $GOPATH/src/messageBoard
```
use port value in ini file
```
$go run main.go
```
or set new port
```
$go run main.go -port 8080
```
## Features
+ RESTful API
+ log
+ Jwt-go
+ Gin
+ Graceful stop
+ App configurable