Skip to content

Commit 088a74e

Browse files
doc: add recommendations about resource limits optimizations (#5276)
* doc: add recommendations about resource limits optimizations Signed-off-by: Camila Macedo <[email protected]> * address suggestions nits Signed-off-by: Camila Macedo <[email protected]>
1 parent 0ae0cd9 commit 088a74e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

website/content/en/docs/best-practices/common-recommendation.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,8 @@ spec:
5050
- For Ansible-based operators, you can also use [Molecule][molecule], an Ansible testing framework. For further information see [Testing with Molecule][molecule-tests]
5151
- For Helm-based operators, you can also use [Chart tests][helm-chart-tests]
5252
- Ensure that you checked the [Can I customize the projects initialized with operator-sdk?][faq] and understand the [Project Layout][project-layout] before starting to do your customizations as please you on top.
53+
- Optimize manager resource values in `config/manager/manager.yaml` according to project requirements. It is recommended to define resources limits in order to follow good practices and for security reasons. More info: [Managing Resources for Containers][k8s-manage-resources] and [Docker Security Cheat Sheet][docker-cheats].
54+
- Look for `TODO(user)` in the source code generated by the CLI to ensure that you follow all suggested customizations.
5355
- If you will integrate your project with OLM then, also check its [Best Practices][olm-best-practices] section.
5456

5557
[env-test]: https://pkg.go.dev/sigs.k8s.io/controller-runtime/pkg/envtest
@@ -69,3 +71,5 @@ spec:
6971
[molecule-tests]: /docs/building-operators/ansible/testing-guide
7072
[helm-chart-tests]: https://helm.sh/docs/topics/chart_tests/
7173
[envtest]: https://pkg.go.dev/sigs.k8s.io/controller-runtime/pkg/envtest
74+
[docker-cheats]: https://cheatsheetseries.owasp.org/cheatsheets/Docker_Security_Cheat_Sheet.html#rule-7-limit-resources-memory-cpu-file-descriptors-processes-restarts
75+
[k8s-manage-resources]: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/

0 commit comments

Comments
 (0)