mirror of
https://github.com/certbot/certbot.git
synced 2026-06-07 07:42:08 -04:00
* Create bootstrap script * Delete a whole bunch of the bootstrap script * modify test_tests to use new script * put python version checking in back in * add x * call the venv creation from inside the bootstrap * add targets back * modify test_apache2 to use new format * shouldn't need virtualenv on rhel * readd targets * Update test_sdists to use new script * move setting up venv back out of script so it's not run with sudo * take venv3.py call out of bootstrap in all scripts * add additional python3-devel pkg name * fix test_sdists * enable additional rhel7 repos * clean up code and comments * Update tests and instructions to use auto_targets.yaml with test_leauto_upgrades.sh and test_letsencrypt_auto_certonly_standalone.sh * only install python3-devel.x86_64 for rhel7 * Upgrade python version for debian in test_apache2.sh * don't run test_tests or test_sdists on debian 9 or ubuntu 16.04 * Add 20.04 and 20.04 arm images to targets.yaml * use pyenv to upgrade to python3.5 * remove arm64 instance because it's having auth trouble * correct pyenv usage on ubuntu * add arm64 target to targets.yaml * replace debian 9 arm64 with ubuntu 20 * don't try to upgrade a perfectly good python version * let's just add ubuntu20 to apache2_targets while we're here * uncomment test_apache2 * move adding python3-devel.x86_64 to bootstrap_os_packages to avoid potential race condition * no need to specify the arch once extra rhel7 repos enabled * explicitly specify python3 * don't fail if we can't enable rhel7 extras * capture python36-devel as well
46 lines
1.2 KiB
Bash
Executable file
46 lines
1.2 KiB
Bash
Executable file
#!/bin/sh -xe
|
|
|
|
cd letsencrypt
|
|
|
|
BOOTSTRAP_SCRIPT="tests/letstest/scripts/bootstrap_os_packages.sh"
|
|
VENV_PATH=venv3
|
|
|
|
# install OS packages
|
|
sudo $BOOTSTRAP_SCRIPT
|
|
|
|
if command -v python && [ $(python -V 2>&1 | cut -d" " -f 2 | cut -d. -f1,2 | sed 's/\.//') -eq 26 ]; then
|
|
# RHEL/CentOS 6 will need a special treatment, so we need to detect that environment
|
|
# Enable the SCL Python 3.6 installed by letsencrypt-auto bootstrap
|
|
PATH="/opt/rh/rh-python36/root/usr/bin:$PATH"
|
|
fi
|
|
|
|
# setup venv
|
|
CERTBOT_PIP_NO_BINARY=:all: tools/venv3.py --requirement letsencrypt-auto-source/pieces/dependency-requirements.txt
|
|
. "$VENV_PATH/bin/activate"
|
|
# pytest is needed to run tests on some of our packages so we install a pinned version here.
|
|
tools/pip_install.py pytest
|
|
|
|
PLUGINS="certbot-apache certbot-nginx"
|
|
TEMP_DIR=$(mktemp -d)
|
|
|
|
# build sdists
|
|
for pkg_dir in acme certbot $PLUGINS; do
|
|
cd $pkg_dir
|
|
python setup.py clean
|
|
rm -rf build dist
|
|
python setup.py sdist
|
|
mv dist/* $TEMP_DIR
|
|
cd -
|
|
done
|
|
|
|
VERSION=$(python letsencrypt-auto-source/version.py)
|
|
# test sdists
|
|
cd $TEMP_DIR
|
|
for pkg in acme certbot $PLUGINS; do
|
|
tar -xvf "$pkg-$VERSION.tar.gz"
|
|
cd "$pkg-$VERSION"
|
|
python setup.py build
|
|
python setup.py test
|
|
python setup.py install
|
|
cd -
|
|
done
|