Merge "Put devstack-version info into separate file" into stable/ocata
This commit is contained in:
commit
64582c2ac6
12
functions
12
functions
|
@ -691,6 +691,18 @@ function enable_kernel_bridge_firewall {
|
|||
done
|
||||
}
|
||||
|
||||
# Save some state information
|
||||
#
|
||||
# Write out various useful state information to /etc/devstack-version
|
||||
function write_devstack_version {
|
||||
cat - > /tmp/devstack-version <<EOF
|
||||
DevStack Version: ${DEVSTACK_SERIES}
|
||||
Change: $(git log --format="%H %s %ci" -1)
|
||||
OS Version: ${os_VENDOR} ${os_RELEASE} ${os_CODENAME}
|
||||
EOF
|
||||
sudo install -m 644 /tmp/devstack-version /etc/devstack-version
|
||||
rm /tmp/devstack-version
|
||||
}
|
||||
|
||||
# Restore xtrace
|
||||
$_XTRACE_FUNCTIONS
|
||||
|
|
7
stack.sh
7
stack.sh
|
@ -190,6 +190,9 @@ if [[ ! -r $TOP_DIR/stackrc ]]; then
|
|||
fi
|
||||
source $TOP_DIR/stackrc
|
||||
|
||||
# write /etc/devstack-version
|
||||
write_devstack_version
|
||||
|
||||
# Warn users who aren't on an explicitly supported distro, but allow them to
|
||||
# override check and attempt installation with ``FORCE=yes ./stack``
|
||||
if [[ ! ${DISTRO} =~ (trusty|xenial|yakkety|7.0|wheezy|sid|testing|jessie|f23|f24|f25|rhel7|kvmibm1) ]]; then
|
||||
|
@ -1454,6 +1457,10 @@ if [[ -n "$DEPRECATED_TEXT" ]]; then
|
|||
echo_summary "WARNING: $DEPRECATED_TEXT"
|
||||
fi
|
||||
|
||||
# Useful info on current state
|
||||
cat /etc/devstack-version
|
||||
echo
|
||||
|
||||
# Indicate how long this took to run (bash maintained variable ``SECONDS``)
|
||||
echo_summary "stack.sh completed in $SECONDS seconds."
|
||||
|
||||
|
|
Loading…
Reference in New Issue