Skip to content

Commit 54b722d

Browse files
mjsambolLeonid Podolinskiy
andauthored
Small text corrections (#11)
* Small text corrections * typos in drawings --------- Co-authored-by: Moshe Sambol <[email protected]> Co-authored-by: Leonid Podolinskiy <[email protected]>
1 parent 752a21c commit 54b722d

File tree

3 files changed

+11
-9
lines changed

3 files changed

+11
-9
lines changed

docs/how.md

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,20 @@
11
### How it works
22

3-
- User creating custom resource of `Kind: LightrunJavaAgent`
3+
- The User begins by creating a custom resource of `Kind: LightrunJavaAgent`
44
[Example](../config/samples/agents_v1beta_lightrunjavaagent.yaml)
55
[Detailed explanation of CR fields](custom_resource.md)
6-
- Controller is receiving all updates about all CRs(custom resources)`LightrunJavaAgent` across all the cluster (or specific namespaces). Every event triggering reconcile loop of the controller. You can find logic of this loop [here](reconcile_loop.excalidraw.png)
7-
- When triggered it is doing several actions:
6+
- The Controller receives all updates about all CRs (custom resources) of kind `LightrunJavaAgent` across all the cluster or specific namespaces
7+
(subject to how it's been installed).
8+
Every event related to these CRs triggers the reconcile loop of the controller. You can find logic of this loop [here](reconcile_loop.excalidraw.png)
9+
- When triggered, the controller performs several actions:
810
- Check if it has access to deployment
9-
- Fetch data from the specified in CR secret
11+
- Fetch data from the CR secret
1012
- Create config map with agent config from CR data
11-
- Patching deployment:
13+
- Patch the deployment:
1214
- insert init container
1315
- add volume
14-
- map that volume to specified container
15-
- add/update specified ENV variable in order to let Java know where agent is placed
16-
- After deployment is being patched, k8s will `recreate all the pods` in the deployment. New Pods will be using Lightrun agent from their start
17-
- If user deleting `LightrunJavaAgent` CR, controller will rollback all the changes to deployment. This will trigger `recreation of all pods` again
16+
- map that volume to the specified container
17+
- add/update specified ENV variable in order to let Java know where agent files are found (the mapped volume)
18+
- After deployment is patched, k8s will `recreate all the pods` in the deployment. New Pods will be initialized with the Lightrun agent
19+
- If user deletes the `LightrunJavaAgent` CR, the Controller will roll back all the changes to deployment. This will trigger `recreation of all pods` again
1820
- [High level diagram](resource_relations.excalidraw.png) of resources created/edited by the operator

docs/reconcile_loop.excalidraw.png

-219 Bytes
Loading
-137 Bytes
Loading

0 commit comments

Comments
 (0)