Katana ML Skipper Workflow
Returns queue name, based on task ID. This allows to route event to the correct queue, without hardcoding logic in the Web API.
File Structure
.
- models.py
- router.py
- workflow.json
- workflow.py
- endpoint.py
- Dockerfile
- README.md
- workflow-pod.yaml
- requirements.txt
api
Instructions
To run all services, check instructions in Getting Started
Run the service without Docker
- Install libraries
- Start FastAPI
- Workflow FastAPI endpoints
pip install -r requirements.txt
uvicorn endpoint:app --port=5000 --reload
http://127.0.0.1:5000/docs
Build and run individual container
- Build container
- Run container
- Workflow FastAPI endpoints
docker build --tag katanaml/skipper-workflow .
docker run -it -d --name skipper-workflow -p 5000:5000 katanaml/skipper-workflow:latest
http://127.0.0.1:5000/docs
Build and run Kubernetes Pod
- Create namespace
- Create Pod
- Check Pod status
- Describe Pod
- Open Pod port for testing purposes
- Open Pod logs
- Test URL
- Check Pod service
- Delete Deployment
- Delete all resources
kubectl create ns katana-skipper
kubectl apply -n katana-skipper -f workflow-pod.yaml
kubectl get -n katana-skipper pods
kubectl describe -n katana-skipper pods skipper-workflow
kubectl port-forward -n katana-skipper deploy/skipper-workflow 5000:5000
kubectl logs -n katana-skipper -f -l app=skipper-workflow
http://localhost:5000/docs
kubectl get -n katana-skipper svc skipper-workflow
kubectl delete -n katana-skipper -f workflow-pod.yaml
kubectl delete all --all -n katana-skipper
License
Licensed under the Apache License, Version 2.0. Copyright 2020-2021 Katana ML, Andrej Baranovskij. Copy of the license.