{"id":22547512,"url":"https://github.com/firmanjs/test-template-gin","last_synced_at":"2025-08-23T03:40:07.153Z","repository":{"id":116875374,"uuid":"387985691","full_name":"firmanJS/test-template-gin","owner":"firmanJS","description":null,"archived":false,"fork":false,"pushed_at":"2021-07-21T07:22:55.000Z","size":9,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-29T20:37:50.473Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/firmanJS.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":"2021-07-21T03:50:21.000Z","updated_at":"2021-07-21T15:44:17.000Z","dependencies_parsed_at":null,"dependency_job_id":"48e084d0-13b9-4f4d-b889-fdefd14d9d7c","html_url":"https://github.com/firmanJS/test-template-gin","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":"dipeshdulal/clean-gin","purl":"pkg:github/firmanJS/test-template-gin","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firmanJS%2Ftest-template-gin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firmanJS%2Ftest-template-gin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firmanJS%2Ftest-template-gin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firmanJS%2Ftest-template-gin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/firmanJS","download_url":"https://codeload.github.com/firmanJS/test-template-gin/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firmanJS%2Ftest-template-gin/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271739244,"owners_count":24812529,"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","status":"online","status_checked_at":"2025-08-23T02:00:09.327Z","response_time":69,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2024-12-07T15:12:08.765Z","updated_at":"2025-08-23T03:40:07.106Z","avatar_url":"https://github.com/firmanJS.png","language":"Go","readme":"## Clean Gin\n\nTrying to implement clean architecture with gin framework.\n\n#### Environment Variables\n\n| Key            | Value                    | Desc                             |\n| -------------- | ------------------------ | -------------------------------- |\n| `SERVER_PORT`  | `5000`                   | Port at which app runs           |\n| `ENV`          | `development,production` | App running Environment          |\n| `LOG_OUTPUT`   | `./server.log`           | Output Directory to save logs    |\n| `DB_USER`      | `username`               | Database Username                |\n| `DB_PASS`      | `password`               | Database Password                |\n| `DB_HOST`      | `0.0.0.0`                | Database Host                    |\n| `DB_PORT`      | `3306`                   | Database Port                    |\n| `DB_NAME`      | `test`                   | Database Name                    |\n| `JWT_SECRET`   | `secret`                 | JWT Token Secret key             |\n| `ADMINER_PORT` | `5001`                   | Adminer DB Port                  |\n| `DEBUG_PORT`   | `5002`                   | Port that delve debugger runs in |\n\n#### Migration Commands\n⚓️ \u0026nbsp; Add argument `p=host` if you want to run the migration runner from the host environment instead of docker environment. \nCheck [#19](https://github.com/dipeshdulal/clean-gin/issues/19) for more details. eg; `make p=host migrate-up`\n\n| Command             | Desc                                           |\n| ------------------- | ---------------------------------------------- |\n| `make migrate-up`   | runs migration up command                      |\n| `make migrate-down` | runs migration down command                    |\n| `make force`        | Set particular version but don't run migration |\n| `make goto`         | Migrate to particular version                  |\n| `make drop`         | Drop everything inside database                |\n| `make create`       | Create new migration file(up \u0026 down)           |\n\n#### Checklist\n\n- [x] Implement Dependency Injection (go-fx)\n- [x] Routing (gin web framework)\n- [x] Environment Files\n- [x] Logging (file saving on `production`) [zap](https://github.com/uber-go/zap)\n- [x] Middlewares (cors)\n- [x] Database Setup (mysql)\n- [x] Models Setup and Automigrate (gorm)\n- [x] Repositories\n- [x] Implementing Basic CRUD Operation\n- [x] Authentication (JWT)\n- [x] Migration\n- [x] Dockerize Application with Debugging Support Enabled. Debugger runs at `5002`. Vs code configuration is at `.vscode/launch.json` which will attach debugger to remote application.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirmanjs%2Ftest-template-gin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffirmanjs%2Ftest-template-gin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirmanjs%2Ftest-template-gin/lists"}