You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
efactor: improve deploy config handling for CPU and memory limits
- Simplify deploy config check by using single if-let binding
- Fix typo: "estart_policy" -> "restart_policy"
- Make CPU/memory limits optional in buildService (only add if configured)
- Avoid hardcoded defaults that may override container/image defaults
// Handle 'deploy' configuration (note that this tool doesn't fully support it)
369
-
ifservice.deploy !=nil{
369
+
ifletdeploy = service.deploy{
370
370
print("Note: The 'deploy' configuration for service '\(serviceName)' was parsed successfully.")
371
-
print(
372
-
"However, this 'container-compose' tool does not currently support 'deploy' functionality (e.g., replicas, resources, update strategies) as it is primarily for orchestration platforms like Docker Swarm or Kubernetes, not direct 'container run' commands."
373
-
)
374
-
print("The service will be run as a single container based on other configurations.")
if deploy.mode !=nil || deploy.replicas !=nil || deploy.restart_policy !=nil{
383
+
print("Note: The 'deploy' configuration for service '\(serviceName)' includes features (mode, replicas, restart_policy) that are not supported by this tool.")
0 commit comments