5 Commits

Author SHA1 Message Date
Tony Breeds
500fc92f17 Fix task name to reflect correct distro
Change-Id: I4ac5bdd6ab27c460b8864b75157a8487128d5a76
2024-07-09 09:12:13 +10:00
Ian Wienand
c921954649
pip: use latest instead of upgrade
I'm not sure if this is clearer or not (which is why I proposed it
separately here).

From inspection of the code, adding "state: latest" just means Ansible
runs "install -U" ... which is pretty much the same thing as adding
--upgrade.  Which is clearer, I'm not sure?

Change-Id: I6e31523686555e33d062f3b05f2385d7e21e2620
2022-12-06 17:28:09 +11:00
Ian Wienand
4fa8d2dd39
create-venv: make upgrade venv once per day
This was inspired by a similar change
I78a914f71cef687f09fcfee0f3f498b79d810f5d.  In the bootstrap-bridge
production, we are calling create-venv every time we fire off a set of
production jobs.  While it's good to keep the venv updated, it doesn't
need to happen hourly.

This writes the requirements to a file, and only installs it if the
template updates (i.e. if the venv is fresh, the dependencies updated
or we updated the daily timestamp).

Change-Id: I7a70b73fb907b923f47a2a0de72e21649c15e05f
2022-12-06 17:28:09 +11:00
Jeremy Stanley
2d9d24d07d Also pin pip/setuptools when creating Xenial venvs
We still have some Ubuntu Xenial servers, so cap the max usable pip
and setuptools versions in their venvs like we already do for
Bionic, in order to avoid broken installations. Switch our
conditionals from release name comparisons to version numbers in
order to more cleanly support ranges. Also make sure the borg run
test is triggered by changes to the create-venv role.

Change-Id: I5dd064c37786c47099bf2da66b907facb517c92a
2022-08-10 19:35:10 +00:00
Ian Wienand
ea08cdbd16 create-venv: add role; use in install-borg
As noted inline, make a create-venv role that brings in appropriate
versions on Bionic.

This was noticed because pip is trying to install borgbackup with
setuptools_scm 7.0.5, which doesn't support Python 3.6.  We use this
new role to create the venv correctly.

Change-Id: I81fd268a9354685496a75e33a6f038a32b686352
2022-08-10 10:14:51 +10:00