-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
👌(typo) updating code due to code review changes
- Loading branch information
Showing
13 changed files
with
46 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
--- | ||
# Get deployment_stamp from a route | ||
|
||
- name: Get deployment_stamp of route[{{ app.name }}-{{ prefixe }}] | ||
- name: Get deployment_stamp from route[{{ app.name }}-{{ prefix }}] | ||
openshift_raw: | ||
definition: "{{ lookup('template', 'templates/openshift/common/utils/get_deployment_stamp_form_route.yml.j2') | from_yaml }}" | ||
register: my_route | ||
definition: "{{ lookup('template', 'templates/openshift/common/utils/get_deployment_stamp_from_route.yml.j2') | from_yaml }}" | ||
register: app_route | ||
|
||
- name: set_fact route_deployment_stamp | ||
- name: set_fact app_route_deployment_stamp | ||
set_fact: | ||
route_deployment_stamp: "{{ my_route.result.metadata.labels.deployment_stamp }}" | ||
app_route_deployment_stamp: "{{ app_route.result.metadata.labels.deployment_stamp }}" | ||
|
||
- name: Print route_deployment_stamp | ||
debug: msg="[{{ app.name }}] route[{{ app.name }}-{{ prefixe }}] route_deployment_stamp[{{ route_deployment_stamp }}]" | ||
- name: Print app_route_deployment_stamp | ||
debug: msg="[{{ app.name }}] route[{{ app.name }}-{{ prefix }}] app_route_deployment_stamp[{{ app_route_deployment_stamp }}]" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
--- | ||
# Patch routes of all services of one app to the new deployment_stamp | ||
# Patch routes of all services from a single app to the new deployment_stamp | ||
|
||
- name: "[{{ app.name }}] Patch route[{{ app.name }}-{{ prefixe }}] with deployment_stamp[{{ deployment_stamp }}]" | ||
- name: "[{{ app.name }}] Patch route[{{ app.name }}-{{ prefix }}] with deployment_stamp[{{ deployment_stamp }}]" | ||
openshift_raw: | ||
force: true | ||
definition: "{{ lookup('template', 'templates/openshift/common/route/main.yml.j2') | from_yaml }}" | ||
state: present | ||
with_nested: | ||
- "{{ app.services }}" | ||
- "{{ prefixe }}" | ||
- "{{ prefix }}" | ||
when: item.0.host is defined |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,22 @@ | ||
--- | ||
# Patch all apps dest routes with src stack | ||
# Patch app dest route with src stack | ||
|
||
- name: Print switch details | ||
debug: msg="[{{ app.name }}] Switch routes from {{ prefixe_route_src }} to {{ prefixe_route_dest }}" | ||
debug: msg="[{{ app.name }}] Switch routes from {{ prefix_route_src }} to {{ prefix_route_dest }}" | ||
tags: switch | ||
|
||
- include_tasks: deploy_get_stamp_from_route.yml | ||
vars: | ||
prefixe: "{{ prefixe_route_src }}" | ||
prefix: "{{ prefix_route_src }}" | ||
tags: switch | ||
|
||
- include_tasks: deploy_patch_route.yml | ||
vars: | ||
prefixe: "{{ prefixe_route_dest }}" | ||
deployment_stamp: "{{ route_deployment_stamp }}" | ||
prefix: "{{ prefix_route_dest }}" | ||
deployment_stamp: "{{ app_route_deployment_stamp }}" | ||
tags: switch | ||
|
||
- include_tasks: deploy_patch_route.yml | ||
vars: | ||
prefixe: "{{ prefixe_route_src }}" | ||
prefix: "{{ prefix_route_src }}" | ||
tags: switch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...ls/get_deployment_stamp_form_route.yml.j2 → ...ls/get_deployment_stamp_from_route.yml.j2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters