Requiremnets:
- kind
- helm
- docker
kind create cluster --config cluster.yaml
docker build -t ormuco-backend:1.2 .
kind load docker-image ormuco-backend:1.2
docker exec -it $(kind get clusters | head -1)-control-plane crictl images
helm install ormuco-database ./charts/ormuco-database
helm install ormuco-backend ./charts/ormuco-backend
kubectl get pods
kubectl get services
kubectl port-forward service/ormuco-backend 8000:80
# write to the database
curl -X 'POST' \
'http://localhost:8000/items/' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '{
"name": "pencil",
"price": 1.0,
"count": 100
}'
# get a list of items
curl -X 'GET' \
'http://localhost:8000/items/' \
-H 'accept: application/json'
you can also reach the api documentation via: http://localhost:8000/docs