-
Notifications
You must be signed in to change notification settings - Fork 4
Conversation
This looks like it is going to be very useful! Do we have Ansible on these machines? I am wondering if instead of calling out to the specific package manager variants if we can just call Ansible and let it figure out the details of how to get the package installed. |
probably we have Ansible, but in any case, it is Python so we have it (in most cases). |
Ah, so this is intended just to be used with Choco or is it a generic tool installer? From the name I thought it was generic but if it's just Choco then I agree that it is best to just call it directly. |
It is a generic tool installer from my point of view. The initial approach was to be able to install the tools we do need independently of the OS, therefore we could say Then, I found we could even add more specific providers, such as apt, choco, brew and so on in case we wanted to get a more fine granularity to how and what to install., so something like that could also help with:
In both cases, the entrypoint is Ansible could be potentially another provider to be added, there is no restriction regarding what to use and how to use it, but the default behavior is the one that might require some kind of agreement. What do you think? |
it makes sense. |
I thinks this strikes a good balance. We have the precision to call directly into package management systems if we want, or we can use Ansible if we want a higher degree of abstraction. 👍 to this approach. |
What does this PR do?
Provide a new step to install tools in the CI workers using a wrapper.
Why is it important?
Avoid the same scripts to be copied across different repos.
Related issues
Related to elastic/apm-agent-python#730
and elastic/apm-agent-nodejs#1393
Questions
@elastic/observablt-robots , I need your feedback for this particular approach and also the below questions:
apm-agent-dotnet
could use a similar approach.Current pipeline does use a ps1 to install some required tools and the Jenkinsfile does call the ps1 file, see the below snippet:
The proposal could be to delete the ps1 and put the logic in the call to the step in the Jenkinsfile, see the below snippet:
nodejs
versions might require a different way to order them in ps1. See https://github.com/elastic/apm-agent-nodejs/pull/1393/files#diff-860c4fe077b91b560f207db63e491a6aR9 (sort {[version] $_}
)add a provider to enable to customise what we wanna do, for instance:
If the provider parameter is enabled then we might need to use an extra flag, for instance the intallation in the
apm-agent-dotnet
of the VS2019-enterprise requrie some extra packages, so the below snippet is what it's done so far:The Jenkinsfile could do something like the below call: