Skip to content
This repository has been archived by the owner on Mar 16, 2021. It is now read-only.

Commit

Permalink
fixes #8784: defines max_cpu_count for docker compute resource
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitri-d authored and dLobatog committed Jan 20, 2015
1 parent f4c209f commit dba2e43
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/models/foreman_docker/docker.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ def max_memory
16 * 1024 * 1024 * 1024
end

def max_cpu_count
::Docker.info['NCPU'] || 1
end

def available_images
client.images.all
end
Expand Down

0 comments on commit dba2e43

Please sign in to comment.