Professional Documents
Culture Documents
Kuma Meshes Part I
Kuma Meshes Part I
different
What is Kuma?
Intro - What is Kuma?
https://kuma.io/docs/2.6.x/introduction/overview-of-kuma/
Chapter I
01 | Our application
03 | Creating a Cluster
Step 1
Our application
https://github.com/jesperancinha/wild-life-safety-monitor
Chapter I - Our Application
Step 2
Installing all
commands
Chapter I - Our Application
This will be achieved with kind. (kubernetes This will be achieved with kubectl
in docker)
A local registry that we can access inside our A command to allow Kuma to install the
2
deployment environment. 4
environment and inject the sidecars.
This will be achieved with kind This will be achieved with kumactl.
Chapter I
Step 3
Creating
a Cluster
Chapter I - Our Application
Creating a Cluster
Step 4
Creating a
local docker
registry
Chapter I - Our Application
./kind-with-registry.sh
Chapter I - Our Application
Step 5
Going
through
the code
Chapter I - Our Application
wslm.url.collector=http://wlsm-collector-deployment.wlsm-namespace.svc.cluster.local:8081/api/v1/collector
Collector Service
spring.r2dbc.url=r2dbc:postgresql://wlsm-database-deployment.wlsm-namespace.svc.cluster.local:5432/wlsm
Chapter I
Step 6
Making
the deploy
scripts
Chapter I - Our Application
Step 7
Running
the application
Chapter I - Our Application
Exploring
Kuma features
Chapter II - Exploring Kuma features
MeshTrafficPermission
echo "apiVersion: kuma.io/v1alpha1
kind: MeshTrafficPermission
metadata:
namespace: kuma-system
name: mtp
spec:
targetRef:
kind: Mesh
from:
- targetRef:
kind: Mesh
default:
action: Allow" | kubectl apply -f -
Chapter II - Exploring Kuma features
Mesh
echo "apiVersion: kuma.io/v1alpha1
kind: Mesh
metadata:
name: default
spec:
mtls:
enabledBackend: ca-1
backends:
- name: ca-1
type: builtin" | kubectl apply -f -
Chapter II - Exploring Kuma features
MeshTrafficPermission (Deny)
apiVersion: kuma.io/v1alpha1
kind: MeshTrafficPermission
metadata:
namespace: kuma-system
name: mtp
spec:
targetRef:
kind: Mesh
from:
- targetRef:
kind: Mesh
default:
action: Deny" | kubectl apply -f -
Chapter II - Exploring Kuma features
MeshTrafficPermission (Specific)
echo "
apiVersion: kuma.io/v1alpha1
kind: MeshTrafficPermission
metadata:
namespace: kuma-system
name: wlsm-database
spec:
targetRef:
kind: MeshService
name: wlsm-database-deployment_wlsm-namespace_svc_5432
from:
- targetRef:
kind: MeshService
name: wlsm-collector-deployment_wlsm-namespace_svc_8081
default:
action: Allow" | kubectl apply -f -
Chapter II - Exploring Kuma features
MeshFaultInjection (Specific)
echo "
apiVersion: kuma.io/v1alpha1
kind: MeshFaultInjection
metadata:
name: default
namespace: kuma-system
labels:
kuma.io/mesh: default # optional, defaults to `default` if it isn't configured
spec:
targetRef:
kind: MeshService
name: wlsm-collector-deployment_wlsm-namespace_svc_8081
from:
- targetRef:
kind: MeshService
name: wlsm-listener-deployment_wlsm-namespace_svc_8080
default:
http:
- abort:
httpStatus: 500
percentage: 50" | kubectl apply -f -
Project Location
● Source Repository
○ https://github.com/jesperancinha/wild-life-safety-monitor
Use git clone from the command prompt to download the full code base:
You’ll be prompted for a username and password which should be your github account.