4b1d9cfd7d
Fixes #10463 I'm really surprised this flew under the radar for years... By having unique PRNGs, the SSH communicator could and would generate identical ScriptPaths and two provisioners running in parallel could overwrite each other and execute the same script. This would happen because they're both seeded by the current time which could potentially be identical if done in parallel... Instead, we share the rand now so that the sequence is guaranteed unique. As an extra measure of robustness, we also multiple by the PID so that we're also protected against two processes at the same time. |
||
---|---|---|
.. | ||
remote | ||
shared | ||
ssh | ||
winrm | ||
communicator.go | ||
communicator_mock.go | ||
communicator_test.go |