Manually running pipeline builds
Manually trigger a pipeline build
In Codefresh, you have the flexibility to control when your pipeline builds execute, offering both automated and manual options. While pipeline builds through automated triggers are usually the norm, ensuring a swift and continuous integration process, manual builds allows you to initiate a build at your discretion.
Manually running the build for a pipeline allows you to override build settings for the pipeline. On-demand builds are useful for one-off jobs that do not require repetition for example, or to verify changes or when the pipeline build has not been automated as yet. See Manual build run settings.
In addition, with the manual build run option, you can share build settings with colleagues who have access to the same account without running the build. See Share build run settings.
When run, the manually-triggered build is added to the Builds page for monitoring and management like any other build.
Manual build run settings
Here is an example of the build settings available for a manual build run.
The table below describes the settings in the Triggers page.
Manual build run setting | Description |
---|---|
Simulate trigger from | The trigger to simulate for the manual run of the pipeline. All the triggers defined for the pipeline are available. |
Select branch | The branch on which to run the build on. |
Build variables | The variables to use for this build. All the variables defined for the pipeline are displayed. You can modify the values of existing variables or manually add one or more new variables. Clicking the Lock icon, encrpts the variable. |
Advanced options | Select the options to override the behavior for the manual run.
|
Runtime Environment |
|
Share run configuration | Copies the modified or new settings defined for the current run, except for encrypted variables, and generates a URL with the settings appended as query parameters. You can then share the URL with colleagues who have access to the same account. See Sharing manual build run settings. |
Debug | Runs the pipeline in debug mode where you can add breakpoints and use the debug terminal. See Debugging pipelines. |
Run | Triggers a build with the current settings and takes you to the Builds page where you can monitor the pipeline. See Monitoring pipelines. |
Share build run settings
NOTE
This feature is currently in Beta.
Override settings for a pipeline build and share them with colleagues who have access to the same account.
This option is useful to pre-populate build settings without having to redefine the same manually every time. For example, share build settings to test automation for integration with third-party tools, or to trigger pipelines in specific scenarios.
When sharing settings, you can simulate a different trigger, select a different branch, modify existing or add new build variables, and modify the build behavior.
Codefresh generates a URL with the modified and new settings appended as query parameters, while excluding encrypted variables to not compromise security. Shared build settings also do not include the Runtime environment settings defined for the pipeline if any.
The URL opens the Trigger page with the sections expanded to indicate updated/new settings. For easy identification, new or modified Build Variables are highlighted.
- In the Pipelines page, click Run either to the right of the pipeline, or in the Workflows tab of the pipeline.
- Update settings as required.
-
Click Share Run Configuration. Codefresh generates a URL with the new settings appended as query parameters.
NOTE
Encrypted variables are excluded from the generated URL.
- Paste the URL in your browser.
The browser opens the Trigger page with all sections with updates automatically expanded.
You can see in the example below that the encrypted variable in step 2 has not been copied.
Note on Cloud Builds for Codefresh pipelines
Cloud Builds for Codefresh pipelines are disabled for all accounts by default.
Account admins can request Codefresh to enable Cloud Builds for an account. There is no manual action required except to click on the Enable Cloud Builds button as shown below. The timeframe for the response is up to 24 hours.
As an account admin, you can then grant access to users or have the users explicitly request access to a runtime environment to run pipelines.
If you create a free account, to run pipelines, you need to configure Build Runtime settings with a Hybrid Runner runtime environment.
Related articles
Codefresh YAML for pipeline definitions
Triggers in pipelines
Variables in pipelines
Debugging pipelines
Running pipelines locally