a9fbcb1855
Moved the DockerWorker class from module file into its separate file in module_utils directory for future extension. Unit tests changed accordingly. Signed-off-by: Ivan Halomi <ivan.halomi@tietoevry.com> Co-authored-by: Martin Hiner <martin.hiner@tietoevry.com> Change-Id: Ia2a471a9a2805e13b2c20dbf8a7297c23231aae3
18 lines
600 B
Bash
Executable File
18 lines
600 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# NOTE(hinermar): During deployment, Ansible handles module discovery
|
|
# automatically. In testing environment this feature is
|
|
# not present so it's necessary to link module files to environment
|
|
# package directory so they can be discovered by python interpreter.
|
|
|
|
|
|
local_module_utils=${1}/ansible/module_utils
|
|
env_module_utils=${2}/ansible/module_utils
|
|
|
|
for file_path in ${local_module_utils}/*.py; do
|
|
file_name=$(basename ${file_path})
|
|
source=$(realpath ${file_path})
|
|
destination=$(realpath ${env_module_utils})/${file_name}
|
|
ln -fs ${source} ${destination}
|
|
done
|