{"id":23832607,"url":"https://github.com/tuanlc/book-management","last_synced_at":"2025-09-07T12:32:06.557Z","repository":{"id":41256891,"uuid":"508736906","full_name":"tuanlc/book-management","owner":"tuanlc","description":"Book management system","archived":false,"fork":false,"pushed_at":"2022-11-06T14:08:13.000Z","size":11049,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-10-30T18:03:28.842Z","etag":null,"topics":["crud-api","go","golang","grpc","grpc-go","template"],"latest_commit_sha":null,"homepage":"","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/tuanlc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-06-29T14:58:27.000Z","updated_at":"2023-12-12T06:47:08.000Z","dependencies_parsed_at":"2022-07-10T03:18:18.559Z","dependency_job_id":null,"html_url":"https://github.com/tuanlc/book-management","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/tuanlc%2Fbook-management","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tuanlc%2Fbook-management/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tuanlc%2Fbook-management/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tuanlc%2Fbook-management/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tuanlc","download_url":"https://codeload.github.com/tuanlc/book-management/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":232212314,"owners_count":18489366,"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":["crud-api","go","golang","grpc","grpc-go","template"],"created_at":"2025-01-02T14:38:42.267Z","updated_at":"2025-01-02T14:38:42.907Z","avatar_url":"https://github.com/tuanlc.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Book management\n\n![action status](https://github.com/tuanlc/book-management/actions/workflows/ci.yml/badge.svg)\n[![Go Report Card](https://goreportcard.com/badge/github.com/tuanlc/book-management?style=flat-square)](https://goreportcard.com/report/github.com/tuanlc/book-management)\n[![MIT license](https://img.shields.io/badge/license-MIT-brightgreen.svg)](https://opensource.org/licenses/MIT)\n[![Go.Dev reference](https://img.shields.io/badge/go.dev-reference-blue?logo=go\u0026logoColor=white)](https://pkg.go.dev/github.com/tuanlc/book-management)\n\n## Table Of Contents\n- [Motivation](#motivation)\n- [Technologies](#technologies)\n- [Demonstration](#demonstration)\n- [Development](#development)\n- [Production](#production)\n- [License](#license)\n\n## Motivation\nI'm a Golang \u0026 gRPC newbie (August 2022). A good way to practice is working on a real opensource project, so I decided to create \u0026 work on the book management project with these technologies. If you are a newbie as me, don't hesitate to join me in contribute to this project. If you are an experienced developer, I'm highly appreciate you if you can take a look to the project structure, codebase, etc and give me any feedback on mistakes, good practices, etc. Feel free to create [issues](https://github.com/tuanlc/book-management/issues) or join the project [discussion](https://github.com/tuanlc/book-management/discussions)\n\nYou can use this project as the template for the following technologies.\n\n## Technologies\n- Language: [Golang](https://github.com/golang/go)\n- API: [gRPC](https://grpc.io/)\n- ORM: [Gorm](https://pkg.go.dev/gorm.io/gorm)\n- Database: [PostgreSQL](https://www.postgresql.org/)\n- Hot reload: [Air](https://github.com/cosmtrek/air)\n\n## Demonstration\nYou can experiment the project quickly on your local by using [docker compose](https://docs.docker.com/compose/).\n\n### Setup \u0026 up services\n\n```bash\n$ docker-compose pull\n$ docker-compose up -d\n```\n\nYou can verify all service up without any error by:\n```bash\n$ docker-compose ps\n\n               Name                             Command               State                    Ports                  \n----------------------------------------------------------------------------------------------------------------------\nbook-management-server               ./main.out                       Up      0.0.0.0:8080-\u003e8080/tcp,:::8080-\u003e8080/tcp\nbook-management_database-manager_1   entrypoint.sh docker-php-e ...   Up      0.0.0.0:9000-\u003e8080/tcp,:::9000-\u003e8080/tcp\ndatabase                             docker-entrypoint.sh postgres    Up      0.0.0.0:5432-\u003e5432/tcp,:::5432-\u003e5432/tcp\n```\n\nServices:\n- book-management-server: gRPC server is listening on port 8080\n- database: Postgresql database service\n- book-management_database-manager_1: Database management UI service\n\n### Test\nThere is no gRPC client for the project yet. However, you can use Postman to test APIs. Thanks to [Postman](https://blog.postman.com/postman-now-supports-grpc/).\n\nhttps://user-images.githubusercontent.com/7950991/183283953-e9c0d295-2763-477a-ad00-97126879e273.mp4\n\n## Development\n### Prequisite\n- Install hot reload tool: https://github.com/cosmtrek/air\n\n```sh\n$ make deps\n```\n\n### Configure databse DNS\nSet the environment varibale `DATABASE_DNS` to configure database DNS. For example:\n\n```\n$ DATABASE_DNS=host=localhost user=admin password=admin dbname=book-management port=5432 sslmode=disable TimeZone=Asia/Ho_Chi_Minh\n```\n\n### Run in dev mode with hot reload feature\n```sh\n$ make dev\n```\n\n### Unit test\n```sh\n$ make test\n```\n\n## Production\n\n### Run\n```sh\n$ make run\n```\n\n## License\n\n[MIT](https://opensource.org/licenses/MIT)\n\nCopyright (c) 2022-present, Tuan LE CONG\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftuanlc%2Fbook-management","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftuanlc%2Fbook-management","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftuanlc%2Fbook-management/lists"}