External CI Jobs
The External CI Jobs feature lets you integrate external CI tools with Copado in order to add CI jobs as deployment steps to Copado deployments.
Currently, we support the following CI tools and more will be coming in next releases:
External CI jobs can be added to the following locations:
- New deployment step type called External CI. This step type lets you select a preconfigured CI job from a lookup field. Copado will request the execution and wait for its completion, the step will fail or succeed accordingly.
- New External CI Job's related list in the environment layout. Copado will insert the external CI job(s) of an environment as deployment step(s) in every promotion's Deployment record where the environment is the destination of the deployment. This is useful to enforce regression tests every time something is deployed to a particular environment.
- User Story:
- New External CI Job's related list in the user story layout. Copado will insert the external CI job(s) of a user story as deployment step(s) in every promotion's Deployment record whenever the user story is being promoted.
- Create an external CI setting:
- Got to the External CI Setting tab and click on New.
- Select a CI Tool from the picklist.
- Add the CI tool's Endpoint.
- Fill in the Username, Password and API Token fields of your CI tool account.
- Click on Save.
- Validate the connection by clicking on Validate Connection.
- Create an external CI job:
- In the External CI Setting page, click on the Related tab.
- Click on New External CI Job.
- Select an invoke moment (before or after deployment).
- Add a timeout in minutes.
- If the deployment should continue in case the job fails, check Continue on Failure.
- Jobs fail either because of a timeout or because the returned status of the job is 'Failed'.
- Click on Lookup Job and select one of the jobs from the popup window.
- The list of jobs is retrieved from the CI tool.
- You may click on Refresh Cache to update the job list.
- When selected, the job URL will be copied to the Job URL field.
- If the selected job requires parameters to perform and build, then add those parameters by clicking on the Add Build Parameter button.
- Click on Save.
- Add the External CI Job to an environment, a user story or directly in a deployment step of type External CI.
Building Jobs Manually
- In the job to build, click on Build Job from the Detail page layout.
- Once the build request is sent, a message will be shown on top of the page.
External CI Job in a Deployment
- In case an external CI job has a link to a user story or an environment, the job will run automatically during the deployment. For instance, if a job is associated with an environment, that job will be added as a deployment step when a Deployment record is created for that environment.
- Steps order is defined automatically considering the job's setting (Invoke on field). At this point, you can remove or reorder the external job steps from the deployment.
- Once the external CI job is completed, you will be able to see the results by clicking on the flag icon.
- Using Copado and external CI tools mutually from a single environment will allow you to be in charge of each and every step of your deployment process.
- Every build result of an external CI job will be logged in Copado.
- You can reach these result from a related list in the External CI Job,Environment and User Story objects.
- With the results, you can keep track of a Job Build History. You will be able to monitor the status and duration of it.
- When clicking on the link View in [External CI Tool] you can open build result directly in the tool you use.