Merge pull request #7065 from ThomasWaldmann/vagrant-updates

Vagrant updates
This commit is contained in:
TW 2022-10-02 03:19:15 +02:00 committed by GitHub
commit b5e88129b4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 10 deletions

19
Vagrantfile vendored
View file

@ -3,8 +3,8 @@
# Automated creation of testing environments / binaries on misc. platforms
$cpus = Integer(ENV.fetch('VMCPUS', '4')) # create VMs with that many cpus
$xdistn = Integer(ENV.fetch('XDISTN', '4')) # dispatch tests to that many pytest workers
$cpus = Integer(ENV.fetch('VMCPUS', '16')) # create VMs with that many cpus
$xdistn = Integer(ENV.fetch('XDISTN', '16')) # dispatch tests to that many pytest workers
$wmem = $xdistn * 256 # give the VM additional memory for workers [MB]
def packages_debianoid(user)
@ -160,8 +160,9 @@ end
def install_pythons(boxname)
return <<-EOF
. ~/.bash_profile
pyenv install 3.10.2 # tests, version supporting openssl 1.1
pyenv install 3.9.13 # tests, version supporting openssl 1.1, binary build
pyenv install 3.11.0rc2 # tests
pyenv install 3.10.2 # tests
pyenv install 3.9.14 # tests, binary build
pyenv rehash
EOF
end
@ -179,8 +180,8 @@ def build_pyenv_venv(boxname)
. ~/.bash_profile
cd /vagrant/borg
# use the latest 3.9 release
pyenv global 3.9.13
pyenv virtualenv 3.9.13 borg-env
pyenv global 3.9.14
pyenv virtualenv 3.9.14 borg-env
ln -s ~/.pyenv/versions/borg-env .
EOF
end
@ -204,7 +205,7 @@ def install_pyinstaller()
. ~/.bash_profile
cd /vagrant/borg
. borg-env/bin/activate
pip install 'pyinstaller==4.10'
pip install 'pyinstaller==5.4.1'
EOF
end
@ -227,8 +228,8 @@ def run_tests(boxname, skip_env)
. ../borg-env/bin/activate
if which pyenv 2> /dev/null; then
# for testing, use the earliest point releases of the supported python versions:
pyenv global 3.9.13 3.10.2
pyenv local 3.9.13 3.10.2
pyenv global 3.9.14 3.10.2 3.11.0rc2
pyenv local 3.9.14 3.10.2 3.11.0rc2
fi
# otherwise: just use the system python
# some OSes can only run specific test envs, e.g. because they miss FUSE support:

View file

@ -11,6 +11,7 @@ if sys.platform.startswith("win32"):
os.environ["PATH"] = os.pathsep.join(dll_path) + os.pathsep + os.environ["PATH"]
from .archiver import main
# note: absolute import from "borg", it seems pyinstaller binaries do not work without this.
from borg.archiver import main
main()