{"id":44110133,"url":"https://github.com/eneskzlcn/goarch","last_synced_at":"2026-02-08T16:05:57.224Z","repository":{"id":60298030,"uuid":"540202338","full_name":"eneskzlcn/goarch","owner":"eneskzlcn","description":"Goarch is a cli tool the initializes a general Go project template for chosen architecture type. It supports for domain driven microservice architecture, n-layered backend service architecture, n-layered web application architecture for now.","archived":false,"fork":false,"pushed_at":"2022-09-28T06:05:18.000Z","size":106,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2024-06-21T03:05:44.737Z","etag":null,"topics":["cli-application","cobra-cli","golang","microservices-architecture","n-layer-architecture","project-template"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eneskzlcn.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}},"created_at":"2022-09-22T23:15:08.000Z","updated_at":"2024-06-21T03:05:44.738Z","dependencies_parsed_at":"2022-09-27T19:40:28.571Z","dependency_job_id":null,"html_url":"https://github.com/eneskzlcn/goarch","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/eneskzlcn/goarch","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneskzlcn%2Fgoarch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneskzlcn%2Fgoarch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneskzlcn%2Fgoarch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneskzlcn%2Fgoarch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eneskzlcn","download_url":"https://codeload.github.com/eneskzlcn/goarch/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneskzlcn%2Fgoarch/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29236176,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-08T14:18:14.570Z","status":"ssl_error","status_checked_at":"2026-02-08T14:18:14.071Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["cli-application","cobra-cli","golang","microservices-architecture","n-layer-architecture","project-template"],"created_at":"2026-02-08T16:05:56.749Z","updated_at":"2026-02-08T16:05:57.219Z","avatar_url":"https://github.com/eneskzlcn.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"### GOARCH\n\n### About Project\nGoarch is a cli tool that allows user to create a folder\nstructure for golang projects by given architecture. \n\n### How To Install\nAfter you download the latest binary from releases section, you \ncan add it to you PATH to use from anywhere in you computer.\n\n### Usage\n\n```\ngoarch \u003carchitecture\u003e\n```\nThe only command in that tool is the name of the architecture you\nwant to create.\n- **ms:** Stands for domain driven designed microservice architecture\nthat you can see the result directory structure from below `Microservice Structure Look Like` section. Calling\n`goarch ms` in the directory you want to create the architecture is enough to make it work.\n\n- **nlb** Stands for n-layered backend architecture that you can see the result directory\nstructure from below `N-Layered Backend Architecture Looks Like` section. Calling `goarch nlb`\nin the directory you want to create the architecture is enough to make it work.\n\n- **nlw** Stands for n-layered web application architecture that you can see the result directory\n  structure from below `N-Layered Web Architecture Looks Like` section. Calling `goarch nlb`\n  in the directory you want to create the architecture is enough to make it work.\n\n### About .arch files\nThese are the files used as template to create new files with that template content.\n\n### Microservice Structure Look like\n\n```\n📦project\n ┣ 📂.cd\n ┃ ┣ 📂deployment-artifacts\n ┃ ┃ ┣ 📜deployment.yaml\n ┃ ┃ ┣ 📜pv-claim.yaml\n ┃ ┃ ┣ 📜pv.yaml\n ┃ ┃ ┗ 📜service.yaml\n ┃ ┗ 📜cd.yaml\n ┣ 📂.dev\n ┃ ┣ 📜dev.yaml\n ┃ ┣ 📜local.yaml\n ┃ ┣ 📜prod.yaml\n ┃ ┗ 📜qa.yaml\n ┣ 📂cmd\n ┃ ┗ 📜main.go\n ┣ 📂internal\n ┃ ┣ 📂client\n ┃ ┃ ┣ 📂httpclient\n ┃ ┃ ┃ ┣ 📜httpclient.go\n ┃ ┃ ┃ ┗ 📜httpclient_test.go\n ┃ ┃ ┗ 📂rabbitclient\n ┃ ┃ ┃ ┣ 📜rabbitclient.go\n ┃ ┃ ┃ ┗ 📜rabbitclient_test.go\n ┃ ┣ 📂config\n ┃ ┃ ┣ 📜config.go\n ┃ ┃ ┣ 📜config_test.go\n ┃ ┃ ┗ 📜db.go\n ┃ ┣ 📂domain\n ┃ ┃ ┣ 📜domain.go\n ┃ ┃ ┣ 📜handler.go\n ┃ ┃ ┣ 📜handler_test.go\n ┃ ┃ ┣ 📜repository.go\n ┃ ┃ ┣ 📜repository_test.go\n ┃ ┃ ┣ 📜service.go\n ┃ ┃ ┗ 📜service_test.go\n ┃ ┣ 📂mocks\n ┃ ┃ ┗ 📂domain\n ┃ ┃ ┃ ┗ 📜mock_domain_repository.go\n ┃ ┗ 📂util\n ┃ ┃ ┗ 📂ctxutil\n ┃ ┃ ┃ ┗ 📜ctxutil.go\n ┣ 📂logger\n ┃ ┣ 📜logger.go\n ┃ ┣ 📜zap_logger_adapter.go\n ┃ ┗ 📜zap_logger_adapter_test.go\n ┣ 📂postgres\n ┃ ┣ 📜mock_postgres.go\n ┃ ┣ 📜postgres.go\n ┃ ┗ 📜postgres_test.go\n ┣ 📂rabbitmq\n ┃ ┗ 📜rabbitmq.go\n ┣ 📂seed\n ┃ ┣ 📂cmd\n ┃ ┃ ┗ 📜main.go\n ┃ ┣ 📜create_seed.sql\n ┃ ┣ 📜drop_seed.sql\n ┃ ┣ 📜readme.md\n ┃ ┣ 📜seed.go\n ┃ ┗ 📜seed_test.go\n ┣ 📜go.mod\n ┗ 📜main.go\n```\n\n### N-Layered Backend Architecture Look Like\n```\n📦project\n ┣ 📂.cd\n ┃ ┣ 📂deployment-artifacts\n ┃ ┃ ┣ 📜deployment.yaml\n ┃ ┃ ┣ 📜pv-claim.yaml\n ┃ ┃ ┣ 📜pv.yaml\n ┃ ┃ ┗ 📜service.yaml\n ┃ ┗ 📜cd.yaml\n ┣ 📂.dev\n ┃ ┣ 📜dev.yaml\n ┃ ┣ 📜local.yaml\n ┃ ┣ 📜prod.yaml\n ┃ ┗ 📜qa.yaml\n ┣ 📂cmd\n ┃ ┗ 📜main.go\n ┣ 📂internal\n ┃ ┣ 📂api\n ┃ ┃ ┣ 📜api.go\n ┃ ┃ ┗ 📜api_test.go\n ┃ ┣ 📂client\n ┃ ┃ ┣ 📂httpclient\n ┃ ┃ ┃ ┣ 📜httpclient.go\n ┃ ┃ ┃ ┗ 📜httpclient_test.go\n ┃ ┃ ┗ 📂rabbitclient\n ┃ ┃ ┃ ┣ 📜rabbitclient.go\n ┃ ┃ ┃ ┗ 📜rabbitclient_test.go\n ┃ ┣ 📂config\n ┃ ┃ ┣ 📜config.go\n ┃ ┃ ┣ 📜config_test.go\n ┃ ┃ ┗ 📜db.go\n ┃ ┣ 📂core\n ┃ ┃ ┣ 📂client\n ┃ ┃ ┃ ┣ 📂httpclient\n ┃ ┃ ┃ ┃ ┣ 📜httpclient.go\n ┃ ┃ ┃ ┃ ┗ 📜httpclient_test.go\n ┃ ┃ ┃ ┗ 📂rabbitclient\n ┃ ┃ ┃ ┃ ┣ 📜rabbitclient.go\n ┃ ┃ ┃ ┃ ┗ 📜rabbitclient_test.go\n ┃ ┃ ┣ 📂logger\n ┃ ┃ ┃ ┣ 📜logger.go\n ┃ ┃ ┃ ┣ 📜zap_logger_adapter.go\n ┃ ┃ ┃ ┗ 📜zap_logger_adapter_test.go\n ┃ ┃ ┣ 📂postgres\n ┃ ┃ ┃ ┣ 📜mock_postgres.go\n ┃ ┃ ┃ ┣ 📜postgres.go\n ┃ ┃ ┃ ┗ 📜postgres_test.go\n ┃ ┃ ┣ 📂rabbitmq\n ┃ ┃ ┃ ┣ 📜config.go\n ┃ ┃ ┃ ┣ 📜config_test.go\n ┃ ┃ ┃ ┗ 📜db.go\n ┃ ┃ ┣ 📂server\n ┃ ┃ ┃ ┗ 📜server.go\n ┃ ┃ ┗ 📂util\n ┃ ┃ ┃ ┗ 📂ctxutil\n ┃ ┃ ┃ ┃ ┗ 📜ctxutil.go\n ┃ ┣ 📂entity\n ┃ ┃ ┗ 📜user.go\n ┃ ┣ 📂repository\n ┃ ┃ ┣ 📜repository.go\n ┃ ┃ ┗ 📜repository_test.go\n ┃ ┗ 📂service\n ┃ ┃ ┣ 📜repository.go\n ┃ ┃ ┗ 📜repository_test.go\n ┣ 📂seed\n ┃ ┣ 📂cmd\n ┃ ┃ ┗ 📜main.go\n ┃ ┣ 📜create_seed.sql\n ┃ ┣ 📜drop_seed.sql\n ┃ ┣ 📜readme.md\n ┃ ┣ 📜seed.go\n ┃ ┗ 📜seed_test.go\n ┣ 📜go.mod\n ┗ 📜main.go\n```\n\n``` N-Layered Web Application Looks Like\n📦project\n ┣ 📂.cd\n ┃ ┣ 📂deployment-artifacts\n ┃ ┃ ┣ 📜deployment.yaml\n ┃ ┃ ┣ 📜pv-claim.yaml\n ┃ ┃ ┣ 📜pv.yaml\n ┃ ┃ ┗ 📜service.yaml\n ┃ ┗ 📜cd.yaml\n ┣ 📂.dev\n ┃ ┣ 📜dev.yaml\n ┃ ┣ 📜local.yaml\n ┃ ┣ 📜prod.yaml\n ┃ ┗ 📜qa.yaml\n ┣ 📂cmd\n ┃ ┗ 📜main.go\n ┣ 📂internal\n ┃ ┣ 📂client\n ┃ ┃ ┣ 📂httpclient\n ┃ ┃ ┃ ┣ 📜httpclient.go\n ┃ ┃ ┃ ┗ 📜httpclient_test.go\n ┃ ┃ ┗ 📂rabbitclient\n ┃ ┃ ┃ ┣ 📜rabbitclient.go\n ┃ ┃ ┃ ┗ 📜rabbitclient_test.go\n ┃ ┣ 📂config\n ┃ ┃ ┣ 📜config.go\n ┃ ┃ ┣ 📜config_test.go\n ┃ ┃ ┗ 📜db.go\n ┃ ┣ 📂core\n ┃ ┃ ┣ 📂cache\n ┃ ┃ ┃ ┣ 📜cache.go\n ┃ ┃ ┃ ┗ 📜gcache_adapter.go\n ┃ ┃ ┣ 📂client\n ┃ ┃ ┃ ┣ 📂httpclient\n ┃ ┃ ┃ ┃ ┣ 📜httpclient.go\n ┃ ┃ ┃ ┃ ┗ 📜httpclient_test.go\n ┃ ┃ ┃ ┗ 📂rabbitclient\n ┃ ┃ ┃ ┃ ┣ 📜rabbitclient.go\n ┃ ┃ ┃ ┃ ┗ 📜rabbitclient_test.go\n ┃ ┃ ┣ 📂logger\n ┃ ┃ ┃ ┣ 📜logger.go\n ┃ ┃ ┃ ┣ 📜zap_logger_adapter.go\n ┃ ┃ ┃ ┗ 📜zap_logger_adapter_test.go\n ┃ ┃ ┣ 📂mail\n ┃ ┃ ┃ ┣ 📜gomail_adapter.go\n ┃ ┃ ┃ ┗ 📜mail.go\n ┃ ┃ ┣ 📂postgres\n ┃ ┃ ┃ ┣ 📜mock_postgres.go\n ┃ ┃ ┃ ┣ 📜postgres.go\n ┃ ┃ ┃ ┗ 📜postgres_test.go\n ┃ ┃ ┣ 📂rabbitmq\n ┃ ┃ ┃ ┣ 📜config.go\n ┃ ┃ ┃ ┣ 📜config_test.go\n ┃ ┃ ┃ ┗ 📜db.go\n ┃ ┃ ┣ 📂router\n ┃ ┃ ┃ ┣ 📜mux_router_adapter.go\n ┃ ┃ ┃ ┗ 📜router.go\n ┃ ┃ ┣ 📂server\n ┃ ┃ ┃ ┗ 📜server.go\n ┃ ┃ ┣ 📂session\n ┃ ┃ ┃ ┣ 📜college_session_adapter.go\n ┃ ┃ ┃ ┗ 📜session.go\n ┃ ┃ ┗ 📂util\n ┃ ┃ ┃ ┗ 📂ctxutil\n ┃ ┃ ┃ ┃ ┗ 📜ctxutil.go\n ┃ ┣ 📂entity\n ┃ ┃ ┗ 📜user.go\n ┃ ┣ 📂repository\n ┃ ┃ ┣ 📜repository.go\n ┃ ┃ ┗ 📜repository_test.go\n ┃ ┣ 📂service\n ┃ ┃ ┣ 📜repository.go\n ┃ ┃ ┗ 📜repository_test.go\n ┃ ┗ 📂web\n ┃ ┃ ┣ 📂template\n ┃ ┃ ┃ ┣ 📂include\n ┃ ┃ ┃ ┃ ┣ 📜README.md\n ┃ ┃ ┃ ┃ ┣ 📜header.gohtml\n ┃ ┃ ┃ ┃ ┗ 📜layout.gohtml\n ┃ ┃ ┃ ┗ 📜home.gohtml\n ┃ ┃ ┣ 📜handler.go\n ┃ ┃ ┣ 📜home.go\n ┃ ┃ ┣ 📜template.go\n ┃ ┃ ┗ 📜web.go\n ┣ 📂seed\n ┃ ┣ 📂cmd\n ┃ ┃ ┗ 📜main.go\n ┃ ┣ 📜create_seed.sql\n ┃ ┣ 📜drop_seed.sql\n ┃ ┣ 📜readme.md\n ┃ ┣ 📜seed.go\n ┃ ┗ 📜seed_test.go\n ┣ 📜go.mod\n ┗ 📜main.go\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feneskzlcn%2Fgoarch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feneskzlcn%2Fgoarch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feneskzlcn%2Fgoarch/lists"}