Skip to content

Commit

Permalink
[ISV-5091] Add extra parameters variable to podman build command
Browse files Browse the repository at this point in the history
Signed-off-by: Mario Varas <maario.vrs@gmail.com>
  • Loading branch information
mavaras committed Aug 4, 2024
1 parent 7778300 commit ffa8e41
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
1 change: 1 addition & 0 deletions upstream/roles/build_app_registry/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ testing_bin_path: "{{ work_dir }}/bin"
opm_bin_path: "{{ testing_bin_path }}/opm"
bundle_export_dir_app_registry: "{{ work_dir }}/app_registry/upstream-community-operators"
container_tool: "docker"
container_tool_extra_params: ""
opm_container_tool: "docker"
opm_container_tool_index: "docker"
container_push_extra: ""
Expand Down
12 changes: 10 additions & 2 deletions upstream/roles/build_app_registry/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,16 @@

- name: "Building and pushing app registry"
block:
- name: "Build app registry image '{{ app_registry_image }}' using '{{ app_registry_build_file }}'"
shell: "{{ container_tool }} build --no-cache -t {{ app_registry_image }} -f {{ app_registry_build_dir }}/{{ app_registry_build_file }} {{ bundle_export_dir_app_registry | dirname }}"
- name: "Build app registry image '{{ app_registry_image }}' using '{{ app_registry_build_file }}' (!)"
shell: |
cat <<__EOF__ >/usr/share/containers/storage.conf
[storage]
driver = "overlay"
__EOF__
{{ container_tool }} build {{ container_tool_extra_params }} --no-cache -t {{ app_registry_image }} -f {{ app_registry_build_dir }}/{{ app_registry_build_file }} {{ bundle_export_dir_app_registry | dirname }}
- name: next step
shell: "{{ container_tool }} build {{ container_tool_extra_params }} --no-cache -t {{ app_registry_image }} -f {{ app_registry_build_dir }}/{{ app_registry_build_file }} {{ bundle_export_dir_app_registry | dirname }}"

- name: "Push app registry image '{{ app_registry_image }}'"
shell: "{{ container_tool }} push {{ container_push_extra }} {{ app_registry_image }}"
Expand Down

0 comments on commit ffa8e41

Please sign in to comment.