goyangi

Goyangi is a web foundation to help you getting started with a new web project based on Golang.

  • 所有者: dorajistyle/goyangi
  • 平台:
  • 許可證: MIT License
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

Goyangi

Goyangi means cat in Korean.

The goal

The goal of Goyangi project is making a reliable foundation for developers who want to make web services with the Go server.
When the Goyangi project becomes more stable, developers would become lazybones.
Consequently, lazybones could not only show their creativity but also devote themselves to problems what they can solve.
It is also a good example of how to develop a large web application that combined fancy Go packages.

Why?

There are some good frameworks like magic(Beego, Revel...). However, these are too much.
Some developers prefer to using micro frameworks and lightweight packages for flexibility and performance.
It's not easy to select and combine packages though.
So, Goyangi carefully has chosen packages and combined.
Keep it simple and DRY.

How it works?

Goyangi How it works

Getting Started

Pre installation

  • dep - Install the dependency management for Go.
  • PostgreSQL - Install and run the postgresql service. [username: postgres / password: postgres]
  • yarn - Install a dependency management tool.

Clone the source

$ git clone github.com/dorajistyle/goyangi
$ cd goyangi
$ dep ensure

Run server

SOURCE_ROOT $ go run main.go

Migration (First time only)

createdb goyangi_dev -U postgres;
createdb goyangi_test  -U postgres;
createdb goyangi  -U postgres;

Connect to http://localhost:3001/api/v1/commands/migrate while running the server.

Run frontend (Vue.js)

SOURCE_ROOT $ cd frontend/vuejs
VUE_JS_ROOT $ yarn
VUE_JS_ROOT $ yarn serve

Default Login for Goyangi

  • ID : admin
  • password : password

Goyangi Vue.js Home

Goyangi Vue.js Board

Configuration

Backend

You can find all configuration files in ./config

  • api.go : API related configuration.
  • authentication.go : Authentication related configuration.
  • aws.go : If you want to use aws S3, you should setup configuration here.
  • db.go : Be sure that you have a database for migration and run application.
  • email.go : If you want to send an email to users, set your email information.
  • environment.go : It has three types of environments. DEVELOPMENT, TEST, PRODUCTION
  • image.go : Image related configuration.
  • logger.go : Log related configuration.
  • oauth.go : When you want to connect with oauth, set your oauth information.
  • order.go : Ordering of models.
  • pagination.go : Pagination of models.
  • public.go : Public fields of user for privacy.
  • uploader.go : Uploader related configuration.

Features

  • Restful support
  • From Development to Deployment
  • SPA ready

Restful API

User

User is core of web application.

  • User CRUD
  • User Authentication
  • Oauth
  • User role for admin
  • Permissions handling to access each API
  • Email verification
  • Password reset via email
  • Following
  • Activation
  • MD5 for Gravatar
  • Messaging

Article

It is a foundation of a basic content management system(CMS).

  • Article CRUD
  • Liking
  • Comment

Upload

It is a foundation of basic file upload.

  • Upload files to local storage
  • Upload files to amazon aws S3
  • Upload files metadata to database
  • Upload files to other cloud servers
  • Upload csv to database
Image

Image handling included in uploads function.

  • Resize (vips)
  • Filtering (gift)
App management for permissions

It would be a foundation of App management for permissions such as API call permission.

  • [] -

Other API

We can add any foundation API we need.

  • We can add any foundation code that is commonly used in web application.

From Development to Deployment

Testing

  • BDD testing
   $ go run main.go test

Deployment

Install swagger
  go get github.com/yvasiyarov/swagger
Install Asciidoctor
   sudo gem update --system
sudo gem install -n /usr/local/bin asciidoctor -N
   go run goyangi.go generateAPI

SPA ready

Goyangi separates server and frontend clearly. And default SPA frontend used Vue.js.
However, developers can add frontend easily. Are you interested? Develop frontend and put it into 'frontend/' directory.

Frontend Implemantation, API, Server, Vuejs, --, --, --, User, all, registration,login,logout, Article, all, all, Upload, all, -, Image, all, -, ### Packages

Goyangi uses great open source packages. You can check that which packages used in Goyangi web foundation.

Go Packages

Frontend Packages

TODO

  • Decide what functions should be maintained.
  • Implement All server features in Vue.js frontend.
  • Add tons of BDD tests
  • Improve documentation
  • Automatically ignore private configuration when commit using git filter for contributors.

Contribution

Any contributions are more than welcome.

Donation

tips
flattr
bitcoin


Attributions

Goyangi is under the MIT license

主要指標

概覽
名稱與所有者dorajistyle/goyangi
主編程語言CSS
編程語言Go (語言數: 6)
平台
許可證MIT License
所有者活动
創建於2015-04-17 09:00:05
推送於2024-03-26 06:54:10
最后一次提交2023-12-29 14:57:21
發布數0
用户参与
星數148
關注者數11
派生數19
提交數28
已啟用問題?
問題數1
打開的問題數0
拉請求數2
打開的拉請求數5
關閉的拉請求數32
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?