Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(CAT-2052) Pass target container URI instead of container SHA ID to add_feature_to_node() method #574

Merged
merged 1 commit into from
Oct 3, 2024

Commits on Oct 3, 2024

  1. (CAT-2052) Pass target container URI instead of container SHA ID to a…

    …dd_feature_to_node() method
    
    There is a bug in the 'install_agent' task.
    It is supposed to install the agent on a host (a VM or a docker container) using bolt and then add the 'puppet-agent' feature to the host in the litmus_inventory file.
    Bolt returns the SHA ID of the container instead of the localhost URI after it installs the agent.
    The feature is added through the add_feature_to_node() method. The last parameter of the method is being sent as result["target"]. This is fine in the case of VMs since its their IPv4 address and the method is expecting just that.
    But in case of docker containers it is their SHA container ID and the method expecting the localhost:{port} URI. This results in the feature not being added to the host.
    Since bolt is returning the results in the same order it is provided the input 'targets', we can add the feature by indexing the 'targets' array in that order.
    
    See https://perforce.atlassian.net/browse/CAT-2052?focusedCommentId=2970824
    shubhamshinde360 committed Oct 3, 2024
    Configuration menu
    Copy the full SHA
    63424d1 View commit details
    Browse the repository at this point in the history