forked from x/icebergs
add readme
This commit is contained in:
parent
65171bf4d7
commit
21e814083b
59
README.md
59
README.md
@ -1,2 +1,57 @@
|
|||||||
# icebergs
|
# Icebergs.go
|
||||||
后端 冰山架 Back End Frame
|
|
||||||
|
icebergs是一个后端框架,通过模块化、集群化实现资源的无限的扩展与自由的组合。
|
||||||
|
|
||||||
|
## 1 原型 type.go
|
||||||
|
### 1.1 msg.Detail
|
||||||
|
### 1.2 msg.Option
|
||||||
|
### 1.3 msg.Append
|
||||||
|
### 1.4 msg.Result
|
||||||
|
### 1.5 msg.Travel
|
||||||
|
### 1.6 msg.Search
|
||||||
|
### 1.7 msg.Conf
|
||||||
|
### 1.8 msg.Cmd
|
||||||
|
### 1.9 msg.Cap
|
||||||
|
|
||||||
|
## 2 框架 base.go
|
||||||
|
### 2.1 注册模块 Register
|
||||||
|
### 2.2 创建资源 Begin
|
||||||
|
### 2.3 加载配置 _init
|
||||||
|
### 2.4 启动服务 Start
|
||||||
|
### 2.5 保存配置 _exit
|
||||||
|
### 2.6 释放资源 Close
|
||||||
|
|
||||||
|
## 3 基础模块 base/
|
||||||
|
### 3.1 模块中心 base/ctx
|
||||||
|
### 3.2 命令中心 base/cli
|
||||||
|
### 3.3 认证中心 base/aaa
|
||||||
|
### 3.4 网页中心 base/web
|
||||||
|
|
||||||
|
### 3.5 词法中心 base/lex
|
||||||
|
### 3.6 语法中心 base/yac
|
||||||
|
### 3.7 事件中心 base/gdb
|
||||||
|
### 3.8 日志中心 base/log
|
||||||
|
|
||||||
|
### 3.9 网络中心 base/tcp
|
||||||
|
### 3.10 文件中心 base/nfs
|
||||||
|
### 3.11 终端中心 base/ssh
|
||||||
|
### 3.12 数据中心 base/mdb
|
||||||
|
|
||||||
|
## 4 核心模块 core/
|
||||||
|
### 4.1 编程中心 core/code
|
||||||
|
### 4.2 文档中心 core/wiki
|
||||||
|
### 4.3 聊天中心 core/chat
|
||||||
|
### 4.4 团队中心 core/team
|
||||||
|
### 4.5 贸易中心 core/mall
|
||||||
|
|
||||||
|
## 5 配置 conf.go
|
||||||
|
### 5.1 环境 init
|
||||||
|
### 5.2 主机 host
|
||||||
|
### 5.3 启动 boot
|
||||||
|
### 5.4 节点 node
|
||||||
|
### 5.5 用户 user
|
||||||
|
### 5.6 群组 work
|
||||||
|
### 5.7 认证 auth
|
||||||
|
### 5.8 数据 data
|
||||||
|
### 5.9 文件 file
|
||||||
|
|
||||||
|
@ -1,9 +1,10 @@
|
|||||||
package cli
|
package cli
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"bytes"
|
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
"github.com/shylinux/toolkits"
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
|
"bytes"
|
||||||
"os"
|
"os"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
"os/user"
|
"os/user"
|
||||||
|
@ -1,9 +1,10 @@
|
|||||||
package ctx
|
package ctx
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"encoding/json"
|
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
"github.com/shylinux/toolkits"
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
|
"encoding/json"
|
||||||
"os"
|
"os"
|
||||||
"sort"
|
"sort"
|
||||||
)
|
)
|
||||||
|
@ -3,6 +3,7 @@ package gdb
|
|||||||
import (
|
import (
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
"github.com/shylinux/toolkits"
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
"os"
|
"os"
|
||||||
"os/signal"
|
"os/signal"
|
||||||
"syscall"
|
"syscall"
|
||||||
|
@ -1,9 +1,10 @@
|
|||||||
package log
|
package log
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
"github.com/shylinux/toolkits"
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
|
"fmt"
|
||||||
"os"
|
"os"
|
||||||
"path"
|
"path"
|
||||||
)
|
)
|
||||||
|
@ -3,6 +3,7 @@ package mdb
|
|||||||
import (
|
import (
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
"github.com/shylinux/toolkits"
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -2,6 +2,7 @@ package tcp
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
|
|
||||||
"net"
|
"net"
|
||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
package chat
|
package chat
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
_ "github.com/shylinux/icebergs/base"
|
_ "github.com/shylinux/icebergs/base"
|
||||||
"github.com/shylinux/icebergs/base/web"
|
"github.com/shylinux/icebergs/base/web"
|
||||||
"github.com/shylinux/toolkits"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
var Index = &ice.Context{Name: "chat", Help: "聊天模块",
|
var Index = &ice.Context{Name: "chat", Help: "聊天模块",
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
package code
|
package code
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
_ "github.com/shylinux/icebergs/base"
|
_ "github.com/shylinux/icebergs/base"
|
||||||
"github.com/shylinux/icebergs/base/web"
|
"github.com/shylinux/icebergs/base/web"
|
||||||
"github.com/shylinux/toolkits"
|
|
||||||
|
|
||||||
"os"
|
"os"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
|
@ -1,10 +1,12 @@
|
|||||||
package team
|
package team
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
_ "github.com/shylinux/icebergs/base"
|
_ "github.com/shylinux/icebergs/base"
|
||||||
"github.com/shylinux/icebergs/base/web"
|
"github.com/shylinux/icebergs/base/web"
|
||||||
"github.com/shylinux/toolkits"
|
|
||||||
"os"
|
"os"
|
||||||
"path"
|
"path"
|
||||||
"strings"
|
"strings"
|
||||||
|
11
core/shy.go
Normal file
11
core/shy.go
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
package shy
|
||||||
|
|
||||||
|
import (
|
||||||
|
_ "github.com/shylinux/icebergs/base"
|
||||||
|
|
||||||
|
_ "github.com/shylinux/icebergs/core/chat"
|
||||||
|
_ "github.com/shylinux/icebergs/core/code"
|
||||||
|
_ "github.com/shylinux/icebergs/core/mall"
|
||||||
|
_ "github.com/shylinux/icebergs/core/team"
|
||||||
|
_ "github.com/shylinux/icebergs/core/wiki"
|
||||||
|
)
|
@ -1,10 +1,12 @@
|
|||||||
package mall
|
package mall
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
_ "github.com/shylinux/icebergs/base"
|
_ "github.com/shylinux/icebergs/base"
|
||||||
"github.com/shylinux/icebergs/base/web"
|
"github.com/shylinux/icebergs/base/web"
|
||||||
"github.com/shylinux/toolkits"
|
|
||||||
"os"
|
"os"
|
||||||
"path"
|
"path"
|
||||||
"strings"
|
"strings"
|
||||||
|
@ -1,12 +1,14 @@
|
|||||||
package wiki
|
package wiki
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"bytes"
|
|
||||||
"github.com/gomarkdown/markdown"
|
"github.com/gomarkdown/markdown"
|
||||||
|
"github.com/shylinux/toolkits"
|
||||||
|
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
_ "github.com/shylinux/icebergs/base"
|
_ "github.com/shylinux/icebergs/base"
|
||||||
"github.com/shylinux/icebergs/base/web"
|
"github.com/shylinux/icebergs/base/web"
|
||||||
"github.com/shylinux/toolkits"
|
|
||||||
|
"bytes"
|
||||||
"path"
|
"path"
|
||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
|
@ -2,11 +2,7 @@ package main
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/shylinux/icebergs"
|
"github.com/shylinux/icebergs"
|
||||||
_ "github.com/shylinux/icebergs/core/chat"
|
_ "github.com/shylinux/icebergs/core"
|
||||||
_ "github.com/shylinux/icebergs/core/code"
|
|
||||||
_ "github.com/shylinux/icebergs/core/mall"
|
|
||||||
_ "github.com/shylinux/icebergs/core/team"
|
|
||||||
_ "github.com/shylinux/icebergs/core/wiki"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user