Move group_limit & group_wait under boot
Also make formatting the group strategy the responsibility of the commander.
This commit is contained in:
@@ -87,6 +87,10 @@ class Mrsk::Configuration
|
||||
roles.select(&:running_traefik?).flat_map(&:hosts).uniq
|
||||
end
|
||||
|
||||
def boot
|
||||
Mrsk::Configuration::Boot.new(section: raw_config.boot)
|
||||
end
|
||||
|
||||
|
||||
def repository
|
||||
[ raw_config.registry["server"], image ].compact.join("/")
|
||||
@@ -153,15 +157,6 @@ class Mrsk::Configuration
|
||||
end
|
||||
|
||||
|
||||
def group_strategy
|
||||
if group_limit.present?
|
||||
{ in: :groups, limit: group_limit, wait: group_wait }
|
||||
else
|
||||
{}
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
def audit_broadcast_cmd
|
||||
raw_config.audit_broadcast_cmd
|
||||
end
|
||||
@@ -246,12 +241,4 @@ class Mrsk::Configuration
|
||||
raise "Can't use commit hash as version, no git repository found in #{Dir.pwd}"
|
||||
end
|
||||
end
|
||||
|
||||
def group_limit
|
||||
raw_config.group_limit&.to_i
|
||||
end
|
||||
|
||||
def group_wait
|
||||
raw_config.group_wait&.to_i
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user