Michal Zegan | 3a7e073 | 2018-12-19 11:51:26 +0100 | [diff] [blame] | 1 | --- |
| 2 | - name: Load docker images and push into registry |
| 3 | block: |
Michal Ptacek | 200ae72 | 2019-03-21 12:32:20 +0000 | [diff] [blame] | 4 | - name: Register component name for docker login/load |
| 5 | set_fact: |
Michal Zegan | 3a7e073 | 2018-12-19 11:51:26 +0100 | [diff] [blame] | 6 | component: "{{ (item.path | basename | splitext)[0] }}" |
| 7 | |
| 8 | - name: Docker login |
| 9 | docker_login: |
| 10 | registry: "{{ runtime_images[component].registry }}" |
| 11 | username: admin |
| 12 | password: admin123 |
| 13 | |
| 14 | - name: Load and push component {{ component }} |
| 15 | docker_image: |
| 16 | name: "{{ runtime_images[component].registry }}{{ runtime_images[component].path }}" |
| 17 | tag: "{{ runtime_images[component].tag }}" |
Samuli Silvius | f6f5fc4 | 2019-02-13 11:00:39 +0200 | [diff] [blame] | 18 | push: true |
Michal Zegan | 3a7e073 | 2018-12-19 11:51:26 +0100 | [diff] [blame] | 19 | load_path: "{{ item.path }}" |
Michal Zegan | 8e5a7da | 2018-12-20 12:16:56 +0100 | [diff] [blame] | 20 | timeout: 120 |
Samuli Silvius | f6f5fc4 | 2019-02-13 11:00:39 +0200 | [diff] [blame] | 21 | changed_when: false # for idenpotence |