3 ms·
Huh? I really don't understand your argument. Jenkins is better than scripts because you can do more in Jenkins than in scripts? O_O You can do a heck of a lot
by radicalbyte 11y ago
Huh? I really don't understand your argument. Jenkins is better than scripts because you can do more in Jenkins than in scripts? O_O
You can do a heck of a lot more in scripts; you've got a full language with all of the libraries it comes with in order to do stuff.
We've build our current build pipeline with Python scripts:
0. Bootstrap the build environment (installs everything you need to build).
1. Build projects order, order is derived from the intermodule dependency graph.
2. Execute unit test sets based on build parameter + save results in output.
3. Execute integration tests based on build parameter + save results in output.
4. Build distribution packages + save in output.
5. Deploy distribution packages to server based on parameters.
6. Run UI tests against the deployed packages + save results in output.
7. Publish the bits if they're OK.
Most of these steps are in different scripts, which can be called either from orchestration scripts or one-for-one in Jenkins.
All we have Jenkins do is invoke the script(s) then process and report the results.
We've basically got it wrong with the design of our CI tools; they do too much. They should just provide scheduling, invocation, reporting and dashboards over the build process. Expose that as an API and let scripts integrate with it.
- ebiester 11y agoSo, let's say you have 8 projects. In each of the 8 projects, you want to run the same static analysis tool. If the violations go up, you want an email sent out. If any critical errors are there, you want the build failed. In any project, if the build fails, you want the latest commit automatically reverted. Now, do you just copy and paste to each script, or do you have a chain of build processes and logic in the build system?
- Joky 11y agoI was basically answering "If you're putting lots of logic into ANY CI server you're doing it wrong!". There is a separation of concern: the CI server logic is a refactoring of things that are common to any project. If your project have scripts that sends email on build failure, I think you're doing something wrong. You mention at some point "orchestration scripts", this is exactly what Jenkins is supposed to provide help with: orchestration. The important thing IMO is that the boundaries of responsibilities are clearly defined between what a project does and what the orchestration does.