https://github.com/gusarow4321/tinychat
Training project for study microservices
https://github.com/gusarow4321/tinychat
golang grpc kafka kubernetes metrics microservices training
Last synced: about 1 year ago
JSON representation
Training project for study microservices
- Host: GitHub
- URL: https://github.com/gusarow4321/tinychat
- Owner: gusarow4321
- License: mit
- Created: 2022-05-01T11:30:44.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2022-07-18T15:53:25.000Z (over 3 years ago)
- Last Synced: 2025-03-25T23:18:33.834Z (about 1 year ago)
- Topics: golang, grpc, kafka, kubernetes, metrics, microservices, training
- Language: Go
- Homepage:
- Size: 494 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# TinyChat

[](https://codecov.io/gh/gusarow4321/TinyChat)
- [x] Microservices framework: [go-kratos](https://github.com/go-kratos/kratos)
- [x] Api Gateway: [grpc-gateway](https://github.com/grpc-ecosystem/grpc-gateway)
- [x] OpenAPI descriptions with [protoc-gen-openapi](https://github.com/google/gnostic/tree/main/cmd/protoc-gen-openapi)
- [x] PostgreSQL database
- [x] Unit tests with [testify](https://github.com/stretchr/testify)
- [x] Tracing: [Jaeger](https://www.jaegertracing.io/)
- [x] Metrics: [Prometheus](https://prometheus.io/) & [Grafana](https://grafana.com/) dashboards
- [x] Messages Broker: Kafka
- [x] Orchestration: [K8s](https://kubernetes.io/)
- [ ] File storage
- [ ] Deploying to GKE
- [ ] Integration tests
## Build
Build docker images of all services:
```shell
make all-imgs
```
## Docker
Deploy services locally with docker:
```shell
docker compose up -d
```
## Kubernetes
Deploy services on [minikube](https://minikube.sigs.k8s.io/docs/start/) using [helm](https://helm.sh/)
```shell
minikube start --feature-gates=GRPCContainerProbe=true
kubectl create namespace tiny-chat
kubectl config set-context --current --namespace=tiny-chat
kubectl create secret generic grafana-auth \
--from-literal=admin-user=admin \
--from-literal=admin-password=admin
make load-imgs
helm dependency update
helm install tiny-chat tiny-chat-chart
```
To forward pod's port to localhost:
```shell
kubectl port-forward POD_NAME LOCALHOST_PORT:POD_PORT
```