Merge "keystone: all distros are Python3 - use /usr/bin/python3"

This commit is contained in:
Zuul 2020-08-10 20:48:44 +00:00 committed by Gerrit Code Review
commit 5117eeb9fb

View File

@ -5,11 +5,11 @@ set -o pipefail
# Get data on the fernet tokens
# NOTE(mnasiadka): Check for existence of at least two tokens (should exist after bootstrap)
TOKEN_CHECK=$(/usr/bin/python{{ distro_python_version }} /usr/bin/fetch_fernet_tokens.py -t {{ fernet_token_expiry }} -n 2)
TOKEN_CHECK=$(/usr/bin/python3 /usr/bin/fetch_fernet_tokens.py -t {{ fernet_token_expiry }} -n 2)
# Ensure tokens are populated
n=0
while /usr/bin/python{{ distro_python_version }} /usr/bin/fetch_fernet_tokens.py -t 86400 -n 1 | grep -q '"populated": false'; do
while /usr/bin/python3 /usr/bin/fetch_fernet_tokens.py -t 86400 -n 1 | grep -q '"populated": false'; do
if [ $n -lt 10 ]; then
n=$(( n + 1 ))
echo "ERROR: Fernet tokens have not been populated, rechecking in 1 minute"