[UPGRADE] Limit the size allocated to the Nextcloud container #1

Closed
opened 4 years ago by StephanSainleger · 3 comments
Collaborator

The Nextcloud container currently has no limitation of memory. That means it can grow up too the server capacity. In that extreme case, the other containers won't have enough free memory to run.
This situation leads to a global black out of all the containers.

IDEA#1: to have a parameter in the compose.yml file in order to give a limitation to the Nextcloud container. This parameter can be:

  • a percentage of the total memory of the server
  • OR a fixed value (ie: 15G0)

IDEA#2: generalize this parameter to all the containers (Odoo, Rocketchat,...)

The Nextcloud container currently has no limitation of memory. That means it can grow up too the server capacity. In that extreme case, the other containers won't have enough free memory to run. This situation leads to a global black out of all the containers. IDEA#1: to have a parameter in the compose.yml file in order to give a limitation to the Nextcloud container. This parameter can be: - a percentage of the total memory of the server - OR a fixed value (ie: 15G0) IDEA#2: generalize this parameter to all the containers (Odoo, Rocketchat,...)
Owner

Nice idea. Please note that you can already do those things (well most of them).

Indeed, docker-compose value in yaml allow you to pass on docker-compose options... and these exist already:

https://docs.docker.com/compose/compose-file/compose-file-v2/#cpu-and-other-resources

and for units and all:
https://docs.docker.com/engine/reference/run/#runtime-constraints-on-resources

Just keep in mind the docker-compose.yml generated is currently version 2.

Depending if we want to add some level of abstraction to these notions, we can think about adding a specific options right in 0k-compose.

For now here an example of how you can achieve this in your compose.yml:

nexcloud:
  ...
  docker-compose:
    mem_limit: 1g
Nice idea. Please note that you can already do those things (well most of them). Indeed, `docker-compose` value in yaml allow you to pass on docker-compose options... and these exist already: https://docs.docker.com/compose/compose-file/compose-file-v2/#cpu-and-other-resources and for units and all: https://docs.docker.com/engine/reference/run/#runtime-constraints-on-resources Just keep in mind the `docker-compose.yml` generated is currently version 2. Depending if we want to add some level of abstraction to these notions, we can think about adding a specific options right in `0k-compose`. For now here an example of how you can achieve this in your `compose.yml`: ```yaml nexcloud: ... docker-compose: mem_limit: 1g ```
Owner

If you have a general feeling of how resources should always be attributed, or at least decided charm by charm. I could automatically then generate these limit by following your rule.

If you have a general feeling of how resources should always be attributed, or at least decided charm by charm. I could automatically then generate these limit by following your rule.
StephanSainleger closed this issue 1 year ago
Thank you for shearing amazing post this is post very useful for me. <a href="https://adarsh-parkheights.com/">Adarsh Park Heights price</a> <a href="https://adarshproperty.com/">Adarsh Property</a> <a href="http://adarshdevelopers.gen.in/">Adarsh Park Heights in Bangalore</a> <a href="http://sumadhurafolium.co.in">Sumadharu Folium</a> <a href="http://sumadhurafolium.co">SUMADHURA FOLIUM</a> <a href="https://prestigeparksgrove.com/">Prestige Park Grove Whitefield Price</a> <a href="https://prestigeparkgroves.gen.in/">Prestige Park Grove Whitefield</a> <a href="https://adarshdeveloperss.com">Adarsh Tropica Bangalore</a> <a href="https://adarshdevelopers.gen.in/adarsh-tropica/">Adarsh Tropica Bangalore Sarjapur</a> <a href="https://www.theprestigeproperties.in/">Prestige Lavender Fields</a> <a href="https://thebrigadeproperties.com/">Brigade Calista Bangalore</a> <a href="https://adarshparkland.co/">Adarsh Park Land</a>
Sign in to join this conversation.
No Milestone
No Assignees
3 Participants
Notifications
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.