Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add support for specifying max slave count via SPORK_SLAVES_COUNT env…

…ironment variable using magazine run strategy.
  • Loading branch information...
commit a34a51968a99ac5a77acacafa595ec73cc136c78 1 parent a07c59d
@jarmo authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/spork/run_strategy/magazine.rb
View
2  lib/spork/run_strategy/magazine.rb
@@ -19,7 +19,7 @@
class Spork::RunStrategy::Magazine < Spork::RunStrategy
- Slave_Id_Range = 1..2 # Ringserver uses id: 0. Slave use: 1..MAX_SLAVES
+ Slave_Id_Range = 1..(ENV["SPORK_SLAVES_COUNT"] && ENV["SPORK_SLAVES_COUNT"].to_i || 2) # Ringserver uses id: 0. Slave use: 1..MAX_SLAVES
def slave_max
Slave_Id_Range.to_a.size
Please sign in to comment.
Something went wrong with that request. Please try again.