•  
     
    story #14019 automate jenkins job creation & run
Summary
Empty
automate jenkins job creation & run
Empty

The base work is the existing Tuleap Git Branch Source jenkins plugin that already provides a first level of integration between the 2 tools.

The purpose of this story is to make it fully functionnal in a production environment:

  • Unify credentials management to replace using basic auth for REST and git usage (because it's consume too much resources).
    • Need a tuleap self-check scopes for a given key
  • Add a dedicated endpoint to be used for git push triggers
    • On Tuleap side, there must be a configuration project wide (git) to trigger events on the target jenkins.
  • All configuration means must be compatible with Jcaas to automate deployments
  • Clean-up code base

To investigate:

  • How lifecycle of git repo/branch is managed ?
    • In traditional "Git Branch Source" plugins, jenkins polls the remote organisation (in our case Tuleap project) on regular basis to identify new repositories/branches and create corresponding jobs.
    • Is that possible to have a push based approach where Tuleap would notify the target Jenkins about changes ?
  • How the configuration Tuleap <-> Jenkins is done ?
    • At very least there must be a info about the target Jenkins server in Tuleap project to trigger builds on push
    • Do we limit the configuration to "push" or do we have a more generic "Target Jenkins Server(s)" approach that could be later reused for other purpose (like more comprehensive management of the target Jenkins) ?
  • Prepare work for PR feedback integration (spike & complete AC of story #14430)

Reference plugins:

Empty
Empty
Status
Empty
Done
Development
  • [ ] Does it involves User Interface? 
  • [ ] Are there any mockups?
  • [ ] Are permissions checked?
  • [ ] Does it need Javascript development?
  • [ ] Does it need a forge upgrade bucket?
  • [ ] Does it need to execute things in system events?
  • [ ] Does it impact project creation (templates)?
  • [ ] Is it exploratory?
Empty
Details
#14019
Manuel Vacelet (vaceletm)
2020-06-19 11:38
2019-10-14 17:37
3370

References
Referencing story #14019

Git commit

tuleap/tuleap/stable

Make possible to introspect a personnal access key with a REST scope 9b4b79b804
Enable self keyword for REST users/:id 9cdd9bda63
Refactoring: remove global admin.mustache file 91e381f90e
Add a new pane in Git administration when hudson_git is available c6ba47b138
Refactoring: add routing to hudson_git plugin 545ec9f123
Display an empty read only Jenkins pane 49b204e1a6
Add jenkins servers in the git administration UI 25b165f8d7
Display added jenkins server in the table 0b56ec8056
Display feedbacks in form e1389e3a34
Remove jenkins server (UI part) 2fd1525b7c
Delete the jenkins server f1d450f32e
Add a dedicated namespace for Git administration classes 6b54f8eba7
Add information about server defined at project level cd718845bb
Trigger global polling jobs 3d9d582525
Make the information message about the Jenkins server more visible in the webhook menu of the git repository. 0fd9d857c8
Store logs for Jenkins project servers d3cdab6d57
Project jenkins server's logs are displayed in a modal c3b8e803f3
Display project servers in repository admin view 0a11d36d7c
XML import of project Jenkins server 837a54e2af
Check in backend that the provided URL is an URL f692febfaf
XML export of project Jenkins server 4c32ad7cc2
Send a notification to Jenkins to trigger a job of from the Tuleap Plugin Branch Source f1848d4845
Add logs for XML import/export 9adf3954fd
"Jenkins" should be capitalized cf4d8d70a7
Check in backend that the provided URL is an URL for repository jenkins server 04e4d845db
UnableToLaunchBuildException not catched for Jenkins Tuleap plugin notification 5f0dea8b36
Refactoring: split job and polling URL in dedicated tables d2843df7c1
Store the polling logs in the same job bde17cb7fe
Store branch source status code d2c50024f9
Display both (polling and branch source) logs in project jenkins server 5396a5f8a1
Display both (polling and branch source) logs in repository jenkins server a15b808f10
Rename Job class to Log b22e475245
Extract part of JobManager to LogFactory 98db4c89aa
Move last part of JobManager to LogCreator f30f028c9a
Convert GIT_HOOK_POSTRECEIVE_REF_UPDATE event as object fec5981eae
Glossify jenkins logs modal 2e92d1d7b6
Remove feature flag b5dd1aea76
Homogenize webhooks logs modal 28029ff962
Info message should have the same width than the webhooks table below 2fcd6aed8e
Be able to test Jenkins server before adding it a84b4e723a
Add missing asterisk in the 3 add hook modals 2a0f42c923
Remove @ts-ignore usage 231ef390cb
Improve "Test Jenkins server" button UX 1bcfeca156
New /projects/{id}/git_jenkins_servers REST route 31ea9a1a6d
Display number of configured Jenkins servers in Git service homepage header 38baa90d8f
Add a scope and format to /users/:id/membership route 01cb08c83e
Move UGroupLiteralizer into the Tuleap\Project namespace edde35a86d
Add Project information on UserGroupRepresentation 98f6f2321c
Convert GIT_HOOK_POSTRECEIVE_REF_UPDATE event as object a3dcf9d0bf

Follow-ups

User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes