/usr/bin/pkgos-readd-keystone-authtoken-missing-options is in openstack-pkg-tools 75.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | #!/bin/sh
set -e
CONF=${1}
if [ -n "${2}" ] ; then
SECTION=${2}
else
SECTION=keystone_authtoken
fi
if [ -n "${3}" ] ; then
DEFAULT_USERNAME=${3}
else
DEFAULT_USERNAME=admin
fi
if ! [ -r "${CONF}" ] ; then
echo "Could not find ${CONF}"
exit 1
fi
# Calculate start and end of file before and after
# the section starts
SECTION_START=$(grep -n "^\[${SECTION}\]\$" ${CONF} | cut -d: -f1)
FILE_LEN=$(cat ${CONF} | wc -l)
END_OF_FILE=$(( ${FILE_LEN} - ${SECTION_START}))
TEMP=$(mktemp $(basename $0).XXXXXX)
head -n ${SECTION_START} ${CONF} >>${TEMP}
echo "#
# Re-added by openstack-pkg-tools
#
# Complete \"admin\" Identity API endpoint.
auth_url = http://localhost:35357
# Project name for auth.
project_name = service
# Project's domain name for auth.
project_domain_name = default
# Username for auth.
username = ${DEFAULT_USERNAME}
# User's domain name for auth
user_domain_name = default
# Password for auth
#password =" >>${TEMP}
tail -n ${END_OF_FILE} ${CONF} >>${TEMP}
pkgos-fix-config-default ${TEMP} ${SECTION} www_authenticate_uri http://localhost:5000
pkgos-fix-config-default ${TEMP} ${SECTION} auth_type password
pkgos-fix-config-default ${TEMP} ${SECTION} region_name regionOne
mv ${TEMP} ${CONF}
|