{"id":15659036,"url":"https://github.com/servb/e-shop","last_synced_at":"2025-09-04T17:34:16.079Z","repository":{"id":130365304,"uuid":"243850990","full_name":"SerVB/e-shop","owner":"SerVB","description":"A project to learn modern web technologies. MIT licence","archived":false,"fork":false,"pushed_at":"2020-05-19T11:12:58.000Z","size":270,"stargazers_count":24,"open_issues_count":0,"forks_count":4,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-30T22:32:30.731Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Kotlin","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/SerVB.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":"2020-02-28T20:42:34.000Z","updated_at":"2024-12-29T14:05:15.000Z","dependencies_parsed_at":"2023-05-03T21:31:08.439Z","dependency_job_id":null,"html_url":"https://github.com/SerVB/e-shop","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/SerVB%2Fe-shop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SerVB%2Fe-shop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SerVB%2Fe-shop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SerVB%2Fe-shop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SerVB","download_url":"https://codeload.github.com/SerVB/e-shop/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252542068,"owners_count":21764907,"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-10-03T13:14:43.515Z","updated_at":"2025-05-05T17:14:39.422Z","avatar_url":"https://github.com/SerVB.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Build status Badge](https://github.com/SerVB/e-shop/workflows/Build/badge.svg)](https://github.com/SerVB/e-shop/actions)\n[![Tests status Badge](https://github.com/SerVB/e-shop/workflows/Tests/badge.svg)](https://github.com/SerVB/e-shop/actions)\n\n[![Docker-compose Badge](https://img.shields.io/badge/docker-compose-blue.svg)](https://docs.docker.com/compose/)\n![jdbc postgresql Badge](https://img.shields.io/badge/jdbc-postgresql-darkblue.svg)\n![Swagger UI Badge](https://img.shields.io/badge/swagger-ui-black.svg)\n\n[![Kotlin Badge](https://img.shields.io/badge/Kotlin-1.3.71-green.svg)](https://kotlinlang.org/)\n\n[![Exposed Badge](https://img.shields.io/badge/Exposed-0.22.1-green.svg)](https://github.com/papsign/Ktor-OpenAPI-Generator)\n[![gRPC Badge](https://img.shields.io/badge/gRPC-1.28.0-388.svg)](https://grpc.io/)\n[![Kotest Badge](https://img.shields.io/badge/Kotest-4.0.2-green.svg)](https://github.com/kotest/kotest)\n[![Ktor Badge](https://img.shields.io/badge/Ktor-1.3.2-green.svg)](https://ktor.io/)\n[![Ktor-OpenAPI-Generator Badge](https://img.shields.io/badge/Ktor%20OpenAPI%20Generator-646f366-green.svg)](https://github.com/papsign/Ktor-OpenAPI-Generator)\n[![Testcontainrs Badge](https://img.shields.io/badge/Testcontainers-1.13.0-blue.svg)](https://www.testcontainers.org/)\n# e-shop\nA project to learn modern web technologies – backend for an online shop.\n\n## Running in Docker\nYou can run the project easily using Docker:\n```shell script\ndocker-compose up\n```\n\nAfter that, you can check Swagger UI at \u003chttp://localhost:8080/swagger-ui\u003e and \u003chttp://localhost:8081/swagger-ui\u003e for the API description.\n\n## Running locally\nIf you want to check it out locally, you should provide database like this:\n```shell script\ndocker run -it -e POSTGRES_PASSWORD=123 -e POSTGRES_USER=user -e POSTGRES_DB=mydb -p 5432:5432 postgres:9.6\n```\n\nAfter this, you can run `./gradlew :product:run` and `./gradlew :auth:run`. Don't forget about setting env like in docker-compose: `DB_USER=user;DB_HOST=localhost;DB_PORT=5432;DB_DB=mydb;DB_PASSWORD=123;AUTH_PORT=8081;AUTH_HOST=localhost`.\n\n## How does it work\n![Container diagram](https://kroki.io/c4plantuml/svg/eNqdVFtv2jAUfvevOOOJaXSjWyv1sZSg9YIgI-nQniITm2A1sSPbKUPT_vuOjQNUjbapeYh0Ts53Of6sXBtLtW2qkrwTMi8bxmF8kY2VtFRIrj_W7hOZjn7MH9MsncdZNF_O2np5l95m08nXySzqvyfEClsivMUCE7TQtIK10sDPzEbVhMRcGyX7jeF6AI_-3RuBK0Gtw1QPuZKdsbzKblQjGdW7Ps_cFxxuR-AXAXwOamEiq7ViTW4zWovD9Flowii-g1FdlyKnVijZw4kHZUshB_BglXZ1rNWzYNwELxCgBtaNzB2IlsLu4FlQWEyS1FGi304rtLGblz5c5y0mPO7_DUSrPlu1J7Gn8-tH1NIVNdxLKGMLzZNvU1clKIxyh2WFxNCqvb9OcufIReeM_ZPWx6t5IYzVnvOUH6hk-wUNNwYbBhV_E7LgZbgmnckulX4ysBWIa107xavh1RBqpXHt-2Q--3SbpjHyvSI7yeaEyXUDy3kHi6PJZlwUm5XqvnCv2b9jXIxaPAWa57ggWPXEpfd6ORxenkPQKRbxeOANBELJ7RadBfNdYi8yXnDK8JJqVfkD3WrhNK3yQhdfPgeZyc9aGc4-3Ec3KPc3qeMOx7jfJOKwR4VrLpn_p_wB7QiCdA==)\n\n## Rules\n- [x] Public repo.\n- [x] Description.\n- [x] Architecture graph.\n- [x] Swagger UI.\n- [x] Docker-compose.\n\n## Stages\n### 1. 2020.02.08\nRest API:\n- [x] Create a product.\n- [x] Remove a product.\n- [x] Return a list of products.\n- [x] Return a product.\n- [x] Edit a product.\n\n\"Product\" entity:\n* Name.\n* ID.\n* Type.\n\nExtra points:\n- [x] Pagination in list of products.\n- [x] Data storage in DB.\n- [x] Versioning.\n- [x] Logging.\n\n### 2. 2020.02.15\n- [x] Data storage in DB.\n\n### 3. 2020.03.01\n- [x] Docker-compose.\n\n### 4. 2020.03.01\n- [x] Registration (via login+password).\n- [x] Auth (change login+password to access+refresh tokens).\n- [x] A way to change a refresh token to new access+refresh tokens.\n- [x] Validation endpoint.\n- [x] Products changing endpoints must be available only with auth tokens.\n\n### 7. 2020.04.14\n- [x] Replace token validation to gRPC variant.\n- [x] Make protobuf files shared (extract to a module).\n- [x] Hash passwords in storage.\n- [x] Add roles: admin and user.\n    - Admin can create, edit, remove, and view products. Also, they can create a new administrator (however, first admin can be created without admin rights).\n    - User can view products.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fservb%2Fe-shop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fservb%2Fe-shop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fservb%2Fe-shop/lists"}