The Pipelines DSL for this example is available in this repository in the JFrog GitHub account.
Example 1
resources: - name: propertyBag_1 type: PropertyBag configuration: property1: "jfrog" property2: "pipelines" pipelines: - name: pipeline_PropertyBag_1 steps: - name: step_propertyBag_1 type: PowerShell configuration: nodePool: win_2019 inputResources: - name: propertyBag_1 execution: onExecute: - write_output "onExecute" - get-variable -name property1 - get-variable -name property2 onSuccess: - write_output "onSuccess"
Example 2
This example uses two steps, step1
and step2
. When the pipeline runs, the step step2
is triggered, but the step step1
is skipped. This is because, the newVersionOnly
tag is set as true
for the myResource
input resource that is used in this step. During a run, if an input resource's version is not updated and if the newVersionOnly
tag is set as true, it causes the step using that input resource to be skipped.
resources: - name: myResource type: PropertyBag configuration: runNumber: 0 pipelines: - name: myPipeline steps: - name: input1 type: Bash configuration: outputResources: - name: myResource execution: onExecute: - write_output myResource runNumber=${run_number} - echo "test" - name: step1 type: Bash configuration: inputResources: - name: myResource newVersionOnly: true execution: onExecute: - echo "test" - name: step2 type: Bash configuration: inputResources: - name: myResource execution: onExecute: - echo "test"