@@ -69,7 +69,7 @@ def interfaces
69
69
setcode do
70
70
if Facter ::Core ::Execution . which ( 'docker' )
71
71
value = Facter ::Core ::Execution . execute (
72
- "#{ docker_command } version --format '{{json .}}'" , time_limit : 90
72
+ "#{ docker_command } version --format '{{json .}}'" , timeout : 90
73
73
)
74
74
val = JSON . parse ( value )
75
75
end
@@ -81,7 +81,7 @@ def interfaces
81
81
setcode do
82
82
if Facter ::Core ::Execution . which ( 'docker' )
83
83
val = Facter ::Core ::Execution . execute (
84
- "#{ docker_command } swarm join-token worker -q" , time_limit : 90
84
+ "#{ docker_command } swarm join-token worker -q" , timeout : 90
85
85
)
86
86
end
87
87
val
@@ -92,7 +92,7 @@ def interfaces
92
92
setcode do
93
93
if Facter ::Core ::Execution . which ( 'docker' )
94
94
val = Facter ::Core ::Execution . execute (
95
- "#{ docker_command } swarm join-token manager -q" , time_limit : 90
95
+ "#{ docker_command } swarm join-token manager -q" , timeout : 90
96
96
)
97
97
end
98
98
val
@@ -105,20 +105,20 @@ def interfaces
105
105
if docker_version &.match? ( %r{1[0-9][0-2]?[.]\w +} )
106
106
if Facter ::Core ::Execution . which ( 'docker' )
107
107
docker_json_str = Facter ::Core ::Execution . execute (
108
- "#{ docker_command } info --format '{{json .}}'" , time_limit : 90
108
+ "#{ docker_command } info --format '{{json .}}'" , timeout : 90
109
109
)
110
110
begin
111
111
docker = JSON . parse ( docker_json_str )
112
112
docker [ 'network' ] = { }
113
113
114
114
docker [ 'network' ] [ 'managed_interfaces' ] = { }
115
- network_list = Facter ::Core ::Execution . execute ( "#{ docker_command } network ls | tail -n +2" , time_limit : 90 )
115
+ network_list = Facter ::Core ::Execution . execute ( "#{ docker_command } network ls | tail -n +2" , timeout : 90 )
116
116
docker_network_names = [ ]
117
117
network_list . each_line { |line | docker_network_names . push line . split [ 1 ] }
118
118
docker_network_ids = [ ]
119
119
network_list . each_line { |line | docker_network_ids . push line . split [ 0 ] }
120
120
docker_network_names . each do |network |
121
- inspect = JSON . parse ( Facter ::Core ::Execution . execute ( "#{ docker_command } network inspect #{ network } " , time_limit : 90 ) )
121
+ inspect = JSON . parse ( Facter ::Core ::Execution . execute ( "#{ docker_command } network inspect #{ network } " , timeout : 90 ) )
122
122
docker [ 'network' ] [ network ] = inspect [ 0 ]
123
123
network_id = docker [ 'network' ] [ network ] [ 'Id' ] [ 0 ..11 ]
124
124
interfaces . each do |iface |
0 commit comments