install-launch-node: upgrade launch env periodically
This writes the date of the pyproject.toml into a stamp file in the venv. If it updates, we run pip with "latest" which should update the environment. The normal "latest" run should ensure any changes to launch-node get populated as usual. This should ensure we keep things like openstackclient updated, but just once per day. Change-Id: I50674a25da9e1761af8daa78970c473e651791b0
This commit is contained in:
parent
a24509a7d7
commit
19d9360b55
@ -12,10 +12,20 @@
|
||||
group: root
|
||||
mode: '0600'
|
||||
|
||||
# This is used to timestamp the launch-env-req.txt file. This means
|
||||
# we will run --upgrade on the venv once a day, but otherwise leave it
|
||||
# alone.
|
||||
- name: Install node launcher stamp
|
||||
template:
|
||||
src: launch-env-req.txt.j2
|
||||
dest: /usr/launcher-venv/launch-env-req.txt
|
||||
register: _upgrade
|
||||
|
||||
- name: Install node launcher
|
||||
pip:
|
||||
name: 'file:///home/zuul/src/opendev.org/opendev/system-config/launch'
|
||||
virtualenv: '/usr/launcher-venv'
|
||||
state: '{{ "latest" if _upgrade.changed else "present" }}'
|
||||
|
||||
# Admins use openstackclient on the bastion host to deal with cloud
|
||||
# issues. The best version to use is the one from launch node, as
|
||||
|
@ -0,0 +1 @@
|
||||
# Update timestamp: {{ now(fmt='%Y-%m-%d') }}
|
Loading…
Reference in New Issue
Block a user