{"id":20294552,"url":"https://github.com/codingcn/go-web-demo","last_synced_at":"2025-04-11T11:43:08.842Z","repository":{"id":40291060,"uuid":"226287819","full_name":"codingcn/go-web-demo","owner":"codingcn","description":"gin开发搭建架子","archived":false,"fork":false,"pushed_at":"2023-06-11T01:06:03.000Z","size":214,"stargazers_count":9,"open_issues_count":3,"forks_count":4,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-25T08:03:30.732Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/codingcn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-12-06T09:03:46.000Z","updated_at":"2023-06-26T05:48:43.000Z","dependencies_parsed_at":"2024-11-14T15:36:11.825Z","dependency_job_id":"43d7e030-aa9e-4dc1-afb5-9d834bdb5d66","html_url":"https://github.com/codingcn/go-web-demo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codingcn%2Fgo-web-demo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codingcn%2Fgo-web-demo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codingcn%2Fgo-web-demo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codingcn%2Fgo-web-demo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codingcn","download_url":"https://codeload.github.com/codingcn/go-web-demo/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248386161,"owners_count":21095021,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-14T15:29:37.610Z","updated_at":"2025-04-11T11:43:08.823Z","avatar_url":"https://github.com/codingcn.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"## ⚠️重要：该项目已废弃，请访问新项目[https://github.com/go-nunu/nunu](https://github.com/go-nunu/nunu)，获取更好的go web开发体验。\n\n----\n## Golang web框架demo\n\n**Tips：该项目不包含具体业务逻辑，只提供一个项目空架子**\n\n\u003e 几个知名的Go语言Web框架(Echo、Gin和Buffalo)由于没有完备支持所有功能，并不能算是真正意义上的Web框架，但大部分go社区认为它们是的;\n\n\n这类框架虽然带来了更多的灵活性，却导致了大多数`Golang`项目结构十分杂乱(不仅限于web项目...)；\n\n团队开发中，没有制定严格的编码规范，同事的业务代码经常随意乱扔，\n\n**该项目主要提供了一个直接可用的空壳架子，但封装了许多优秀的组件应用组件，可以参考快速构建一个完整的项目。**\n\n\n\n## 功能特性\n\n* 项目结构借鉴[laravel/laravel](https://github.com/laravel/laravel.git)风格，基于gin构建；\n* 平滑更新支持 [cloudflare/tableflip](https://github.com/cloudflare/tableflip)；\n* 请求验证器及中间件支持： 跨域； prometheus； [dgrijalva/jwt-go](https://github.com/dgrijalva/jwt-go)；\n* 日志链路及日志轮转支持： [zap](https://go.uber.org/zap) +context+middleware+[lumberjack.v2](https://gopkg.in/natefinch/lumberjack.v2)；\n* 数据库支持：[gorm](https://github.com/jinzhu/gorm)+[go-redis](https://github.com/go-redis/redis)；\n* 静态配置支持：[toml](https://github.com/BurntSushi/toml)；\n* 计划任务支持：[robfig/cron](https://github.com/robfig/cron)；\n\n\n## 运行\n\n启动 项目\n```\ngit clone https://github.com/codingcn/go-web-demo.git\ncd go-web-demo\ngo run main.go -env=dev\n```\n\n平滑升级（替换go可执行文件后，发送指定信号量）\n```\nkill -HUP  `cat go-web-demo.pid`\n```\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodingcn%2Fgo-web-demo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodingcn%2Fgo-web-demo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodingcn%2Fgo-web-demo/lists"}