Add ability to disable yum update with gating repo
Previously when the gating repo was enabled, we would blindly yum update with the repo. This probably shouldn't be the case as we should just be installing or updating the new packages after the repo has been installed. However to maintain backwards compatibility, a new variable called ib_gating_repo_update has been created with the default of True. To disable the yum update after isntalling built repo, set this to false. Change-Id: I5172134738b5b3d5146e45f1e0a7720b6e1d5a2c Closes-Bug: #1796639
This commit is contained in:
parent
47d0c0e8dd
commit
05b5b272f3
@ -10,6 +10,10 @@
|
||||
# Avoid running yum update, only set up repos
|
||||
repo_setup_run_update: false
|
||||
artg_compressed_gating_repo: "${HOME}/gating_repo.tar.gz"
|
||||
# This should not be enabled because the updating of the packages occurs
|
||||
# durring the upgrade process. For general installation it's ok to have
|
||||
# this enabled, but this needs to be disabled for upgrades
|
||||
ib_gating_repo_update: false
|
||||
roles:
|
||||
- role: repo-setup
|
||||
when: containerized_overcloud_upgrade|default(false)|bool
|
||||
|
@ -39,6 +39,10 @@
|
||||
hosts: undercloud
|
||||
vars:
|
||||
artg_compressed_gating_repo: "${HOME}/gating_repo.tar.gz"
|
||||
# This should not be enabled because the updating of the packages occurs
|
||||
# durring the upgrade process. For general installation it's ok to have
|
||||
# this enabled, but this needs to be disabled for upgrades
|
||||
ib_gating_repo_update: false
|
||||
roles:
|
||||
- build-test-packages
|
||||
- {role: install-built-repo, when: compressed_gating_repo is defined}
|
||||
|
@ -1,3 +1,4 @@
|
||||
---
|
||||
- name: Configure next release repository in the undercloud
|
||||
hosts: undercloud
|
||||
tags:
|
||||
@ -9,10 +10,14 @@
|
||||
dlrn_hash_path: ''
|
||||
dlrn_hash_path_newest: ''
|
||||
artg_compressed_gating_repo: "${HOME}/gating_repo.tar.gz"
|
||||
# This should not be enabled because the updating of the packages occurs
|
||||
# durring the upgrade process. For general installation it's ok to have
|
||||
# this enabled, but this needs to be disabled for upgrades
|
||||
ib_gating_repo_update: false
|
||||
roles:
|
||||
- role: repo-setup
|
||||
- role: build-test-packages
|
||||
- { role: install-built-repo, when: compressed_gating_repo is defined }
|
||||
- {role: install-built-repo, when: compressed_gating_repo is defined}
|
||||
|
||||
- name: Run tripleo-upgrade role to upgrade undercloud
|
||||
hosts: undercloud
|
||||
@ -20,4 +25,3 @@
|
||||
- undercloud-upgrade
|
||||
roles:
|
||||
- role: tripleo-upgrade
|
||||
|
||||
|
@ -17,6 +17,7 @@ Role Variables
|
||||
* `ib_repo_install_log` - path to repositories install script log
|
||||
* `ib_repo_run_live`: false/true - where to run repo install script on host (live host that playbook runs on it) (default: true)
|
||||
* `ib_gating_repo_enabled`: true/false - whether to enable built repo or not (default: true)
|
||||
* `ib_gating_repo_update`: true/false - whether to do a yum update with the gating repo (default: true) This only works if ib_gating_repo_enabled is also enabled. WARNING: This may inadvertently update packages outside of what is being provided by the gating repo.
|
||||
* `ib_repo_file_path`: path to compressed repo built by `build-test-packages` role
|
||||
* `ib_repo_image_inject`: false/true - where to inject and run repo install script on specified image (default: false)
|
||||
* `ib_repo_image_path`: path to image, in case of injecting repositories into the image
|
||||
|
@ -7,6 +7,7 @@ ib_repo_file_path: "{{ ib_repo_workdir}}/gating_repo.tar.gz"
|
||||
ib_repo_image_inject: false
|
||||
ib_repo_image_path: "{{ ib_repo_workdir }}/overcloud-full.qcow2"
|
||||
ib_gating_repo_enabled: true
|
||||
ib_gating_repo_update: true
|
||||
ib_create_web_repo: false
|
||||
# Configure host where gate_repo files exists, if it's not the host
|
||||
# where this role is executed
|
||||
|
@ -30,6 +30,6 @@ priority=1
|
||||
EOF
|
||||
{% endif %}
|
||||
|
||||
{% if ib_gating_repo_enabled|bool %}
|
||||
{% if ib_gating_repo_enabled|bool and ib_gating_repo_update|bool %}
|
||||
{{ ansible_pkg_mgr }} --enablerepo="gating-repo" update -y
|
||||
{% endif %}
|
||||
|
Loading…
x
Reference in New Issue
Block a user