diff --git a/example/pipeline/Example-Pipeline.yaml b/example/pipeline/Example-Pipeline.yaml index 92093cf..c745060 100644 --- a/example/pipeline/Example-Pipeline.yaml +++ b/example/pipeline/Example-Pipeline.yaml @@ -3,25 +3,25 @@ description: 'Pipeline' job_type: multi_project wrappers: - - timestamp: true - - ansicolor: true - - rvm: '{{rvm}}' + - timestamp: true + - ansicolor: true + - rvm: '{{rvm}}' builders: - - multi_job: - phases: - Commit: - jobs: - - name: '{{name}}-Commit' - continue_condition: SUCCESSFUL - Acceptance: - jobs: - - name: '{{name}}-Acceptance' - continue_condiction: SUCCESSFUL - Upgrade: - jobs: - - name: '{{name}}-Upgrade' - continue_condiction: SUCCESSFUL - Release: - jobs: - - name: '{{name}}-Release' - continue_condiction: SUCCESSFUL + - multi_job: + phases: + Commit: + jobs: + - name: '{{name}}-Commit' + continue_condition: SUCCESSFUL + Acceptance: + jobs: + - name: '{{name}}-Acceptance' + continue_condition: SUCCESSFUL + Upgrade: + jobs: + - name: '{{name}}-Upgrade' + continue_condition: SUCCESSFUL + Release: + jobs: + - name: '{{name}}-Release' + continue_condition: SUCCESSFUL diff --git a/example/pipeline/Example-Promotion.yaml b/example/pipeline/Example-Promotion.yaml new file mode 100644 index 0000000..b5feafa --- /dev/null +++ b/example/pipeline/Example-Promotion.yaml @@ -0,0 +1,32 @@ +- promotion: + name: '01. Stage Promotion' + promotion_description: 'Describe the promotion process in play' + job_type: promotion + block_when_downstream_building: false # unless defined? false + block_when_upstream_building: false # unless defined? false + promotion_icon: 'silver' # defaults to gold, silver white blue green orange purple red + promotion_conditions: # follow parameters + - manual: + users: 'authenticated' # || '' + - self_promotion: + even_if_unstable: true # unless defined? false + - parameterized_self_promotion: + parameter_name: 'SOME_ENV_VAR' + parameter_value: true + even_if_unstable: true # unless defined? false + - downstream_pass: + jobs: '{{name}}-Commit' + even_if_unstable: true # unless defined? false + - upstream_promotion: + promotion_name: '01. Staging Promotion' + build_steps: # follow builders + - triggered_job: + name: '{{name}}-Release' # maps to + block_condition: # included in xml only if checked on UI + build_step_failure_threshold: 'FAILURE' # 'FAILURE' # %s(never FAILURE UNSTABLE SUCCESS) + failure_threshold: 'FAILURE' # || # %s(never FAILURE UNSTABLE SUCCESS) + unstable_threshold: 'UNSTABLE' # || # %s(never FAILURE UNSTABLE SUCCESS) + build_parameters: + current: true # unless defined? false + - keep_builds_forever: + value: true diff --git a/example/pipeline/Example-Release.yaml b/example/pipeline/Example-Release.yaml index 32d660e..050a42e 100644 --- a/example/pipeline/Example-Release.yaml +++ b/example/pipeline/Example-Release.yaml @@ -7,6 +7,8 @@ local_branch: '{{git_branch}}' recursive_update: true wipe_workspace: true + promoted_builds: + - '01. Stage Promotion' builders: - shell_command: | sleep 60 diff --git a/example/pipeline/project.yaml b/example/pipeline/project.yaml index b42bf63..45a1ab6 100644 --- a/example/pipeline/project.yaml +++ b/example/pipeline/project.yaml @@ -24,3 +24,5 @@ - '{{name}}-Acceptance' # from template (see dependencies section) - '{{name}}-Upgrade' - '{{name}}-Release' + promotions: + - '01. Stage Promotion'