diskimage-builder/elements/rhel/finalise.d/60-rhsm-unregister

12 lines
217 B
Plaintext
Raw Normal View History

#!/bin/bash
set -e
if [ -n "$DIB_RHSM_USER" ] && [ -n "$DIB_RHSM_PASSWORD" ]; then
if [[ "$DIB_REG_TYPE" == "rhn" ]]; then
rm -rf /etc/sysconfig/rhn/systemid
else
subscription-manager unregister
fi
fi