mirror of
https://github.com/certbot/certbot.git
synced 2026-06-09 08:42:57 -04:00
* add get_certbot_version.sh * Use get_certbot_version.sh in build.py * make test_leauto_upgrades.sh more robust * auto upgrades break tests * OCSP experimental is not needed anymore * Add test_sdists.sh * Use LE_AUTO_VERSION, not repo version * install OS deps earlier * use readlink not realpath * undo changes to build.py * Factor out version code from build.py * Use version.py in test_sdists * Remove get_certbot_version * workaround setuptools breakage
37 lines
1.1 KiB
Bash
Executable file
37 lines
1.1 KiB
Bash
Executable file
#!/bin/bash -xe
|
|
|
|
# $OS_TYPE $PUBLIC_IP $PRIVATE_IP $PUBLIC_HOSTNAME $BOULDER_URL
|
|
# are dynamically set at execution
|
|
|
|
cd letsencrypt
|
|
#git checkout v0.1.0 use --branch instead
|
|
SAVE="$PIP_EXTRA_INDEX_URL"
|
|
unset PIP_EXTRA_INDEX_URL
|
|
export PIP_INDEX_URL="https://isnot.org/pip/0.1.0/"
|
|
|
|
#OLD_LEAUTO="https://raw.githubusercontent.com/letsencrypt/letsencrypt/5747ab7fd9641986833bad474d71b46a8c589247/letsencrypt-auto"
|
|
|
|
|
|
if ! command -v git ; then
|
|
if [ "$OS_TYPE" = "ubuntu" ] ; then
|
|
sudo apt-get update
|
|
fi
|
|
if ! ( sudo apt-get install -y git || sudo yum install -y git-all || sudo yum install -y git || sudo dnf install -y git ) ; then
|
|
echo git installation failed!
|
|
exit 1
|
|
fi
|
|
fi
|
|
BRANCH=`git rev-parse --abbrev-ref HEAD`
|
|
git checkout -f v0.1.0
|
|
./letsencrypt-auto -v --debug --version
|
|
unset PIP_INDEX_URL
|
|
|
|
export PIP_EXTRA_INDEX_URL="$SAVE"
|
|
|
|
git checkout -f "$BRANCH"
|
|
EXPECTED_VERSION=$(grep -m1 LE_AUTO_VERSION letsencrypt-auto | cut -d\" -f2)
|
|
if ! ./letsencrypt-auto -v --debug --version --no-self-upgrade | grep $EXPECTED_VERSION ; then
|
|
echo upgrade appeared to fail
|
|
exit 1
|
|
fi
|
|
echo upgrade appeared to be successful
|