Skip to content

Commit

Permalink
refactor: add release git task
Browse files Browse the repository at this point in the history
  • Loading branch information
jobcespedes committed Nov 27, 2020
1 parent 1f67371 commit 2aa6e1a
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 14 deletions.
15 changes: 1 addition & 14 deletions .ansible-ci/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,17 +48,4 @@
include_tasks: tasks/state/save.yml

- name: release
run_once: true
block:
- name: add changes
include_tasks: tasks/git/add.yml
run_once: false

- name: commit changes
include_tasks: tasks/git/commit.yml

- name: tag version
include_tasks: tasks/git/tag.yml

- name: push changes
include_tasks: tasks/git/push.yml
include_tasks: tasks/git/release.yml
19 changes: 19 additions & 0 deletions .ansible-ci/tasks/git/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
- name: add changes
include_tasks: add.yml
run_once: "{{ release_add_run_once | default(true) }}"
when: release_add | default(true) | bool

- name: commit changes
include_tasks: commit.yml
run_once: "{{ release_commit_run_once | default(true) }}"
when: release_commit | default(true) | bool

- name: tag version
include_tasks: tag.yml
run_once: "{{ release_tag_run_once | default(true) }}"
when: release_tag | default(true) | bool

- name: push changes
include_tasks: push.yml
run_once: "{{ release_push_run_once | default(true) }}"
when: release_push | default(true) | bool
1 change: 1 addition & 0 deletions .ansible-ci/vars/pipeline/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ state_image_match_artifact_tag: false
promote_copy_throttle: 1
artifact_generated_context_task: download
artifact_state_task: download
release_add_run_once: false

0 comments on commit 2aa6e1a

Please sign in to comment.