{"id":13675287,"url":"https://github.com/go-kratos/kratos-layout","last_synced_at":"2025-04-12T20:45:36.945Z","repository":{"id":37388751,"uuid":"318962419","full_name":"go-kratos/kratos-layout","owner":"go-kratos","description":"Kratos Project Template","archived":false,"fork":false,"pushed_at":"2024-08-17T05:22:05.000Z","size":268,"stargazers_count":431,"open_issues_count":7,"forks_count":218,"subscribers_count":17,"default_branch":"main","last_synced_at":"2025-04-03T23:12:04.292Z","etag":null,"topics":["architecture","golang","kratos","layout","micorservices","project","service","template"],"latest_commit_sha":null,"homepage":"http://go-kratos.dev","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/go-kratos.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2020-12-06T05:54:09.000Z","updated_at":"2025-04-03T06:31:51.000Z","dependencies_parsed_at":"2024-08-17T05:37:43.589Z","dependency_job_id":"e8a8ba2a-1406-49bc-9314-60deb1ddf9f3","html_url":"https://github.com/go-kratos/kratos-layout","commit_stats":{"total_commits":140,"total_committers":36,"mean_commits":3.888888888888889,"dds":0.5571428571428572,"last_synced_commit":"a399acaf1d2b5233dda8a0995dee656b6fbc0dc4"},"previous_names":["go-kratos/service-layout"],"tags_count":25,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/go-kratos%2Fkratos-layout","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/go-kratos%2Fkratos-layout/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/go-kratos%2Fkratos-layout/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/go-kratos%2Fkratos-layout/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/go-kratos","download_url":"https://codeload.github.com/go-kratos/kratos-layout/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248631687,"owners_count":21136556,"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":["architecture","golang","kratos","layout","micorservices","project","service","template"],"created_at":"2024-08-02T12:00:37.303Z","updated_at":"2025-04-12T20:45:36.921Z","avatar_url":"https://github.com/go-kratos.png","language":"Go","funding_links":[],"categories":["Uncategorized"],"sub_categories":["Uncategorized"],"readme":"# Kratos Project Template\n\n## Install Kratos\n```\ngo install github.com/go-kratos/kratos/cmd/kratos/v2@latest\n```\n## Create a service\n```\n# Create a template project\nkratos new server\n\ncd server\n# Add a proto template\nkratos proto add api/server/server.proto\n# Generate the proto code\nkratos proto client api/server/server.proto\n# Generate the source code of service by proto file\nkratos proto server api/server/server.proto -t internal/service\n\ngo generate ./...\ngo build -o ./bin/ ./...\n./bin/server -conf ./configs\n```\n## Generate other auxiliary files by Makefile\n```\n# Download and update dependencies\nmake init\n# Generate API files (include: pb.go, http, grpc, validate, swagger) by proto file\nmake api\n# Generate all files\nmake all\n```\n## Automated Initialization (wire)\n```\n# install wire\ngo get github.com/google/wire/cmd/wire\n\n# generate wire\ncd cmd/server\nwire\n```\n\n## Docker\n```bash\n# build\ndocker build -t \u003cyour-docker-image-name\u003e .\n\n# run\ndocker run --rm -p 8000:8000 -p 9000:9000 -v \u003c/path/to/your/configs\u003e:/data/conf \u003cyour-docker-image-name\u003e\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgo-kratos%2Fkratos-layout","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgo-kratos%2Fkratos-layout","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgo-kratos%2Fkratos-layout/lists"}