Compare commits

...

3 Commits

Author SHA1 Message Date
Vlastimil Holer 0b7dbc8e0c
Bump version to 5.4.2.1
7 years ago
Vlastimil Holer f48408bbab
gh-107: Disable password reset
7 years ago
Vlastimil Holer 7dc0e7cff4
gh-102: Optional password reset
7 years ago

@ -25,7 +25,7 @@ set -e
source targets.sh
set +e
VERSION=${VERSION:-5.4.2}
VERSION=${VERSION:-5.4.2.1}
RELEASE=${RELEASE:-1}
MAINTAINER=${MAINTAINER:-OpenNebula Systems <support@opennebula.systems>}
LICENSE=${LICENSE:-Apache 2.0}

@ -27,6 +27,9 @@ fi
GRANT_SUDO=${GRANT_SUDO:-YES}
GRANT_SUDO=$(echo "${GRANT_SUDO}" | tr '[:lower:]' '[:upper:]')
USERNAME_PASSWORD_RESET=${USERNAME_PASSWORD_RESET:-NO}
USERNAME_PASSWORD_RESET=$(echo "${USERNAME_PASSWORD_RESET}" | tr '[:lower:]' '[:upper:]')
if [ "${GRANT_SUDO}" == "YES" ] && [ "${USERNAME}" != "root" ]; then
echo "${USERNAME} ALL=(ALL) NOPASSWD:ALL" >/etc/sudoers.d/one-context
chmod 0440 /etc/sudoers.d/one-context
@ -58,6 +61,6 @@ ${PASSWORD}
${PASSWORD}
EOF
fi
else
elif [ "${USERNAME_PASSWORD_RESET}" = 'YES' ]; then
usermod -p '*' "${USERNAME}"
fi

Loading…
Cancel
Save