https/trust
This commit is contained in:
parent
1c5a852647
commit
38108fe867
1 changed files with 22 additions and 37 deletions
|
@ -579,41 +579,6 @@ ${SPCD_PROJECT_ROOT}$(basename "${GITHUB_SERVER_URL}")"
|
||||||
esac
|
esac
|
||||||
spcd_split
|
spcd_split
|
||||||
spcd_os_printenv "SPCD_PM"
|
spcd_os_printenv "SPCD_PM"
|
||||||
# set package manager variables
|
|
||||||
case "${SPCD_PM}" in
|
|
||||||
"${SPCD_PM_DNF}")
|
|
||||||
SPCD_PM_HTTPS_PATH="/etc/dnf/dnf.conf.d/https.conf"
|
|
||||||
SPCD_PM_HTTPS_TEXT="\
|
|
||||||
sslverify=False
|
|
||||||
"
|
|
||||||
;;
|
|
||||||
"${SPCD_PM_APK}")
|
|
||||||
SPCD_PM_HTTPS_PATH="/etc/apk/repositories.d/https"
|
|
||||||
SPCD_PM_HTTPS_TEXT="\
|
|
||||||
--no-verify
|
|
||||||
"
|
|
||||||
;;
|
|
||||||
"${SPCD_PM_PACMAN}")
|
|
||||||
SPCD_PM_HTTPS_PATH="/etc/pacman.d/https.conf"
|
|
||||||
SPCD_PM_HTTPS_TEXT="\
|
|
||||||
SSLVerify = No
|
|
||||||
"
|
|
||||||
;;
|
|
||||||
"${SPCD_PM_APT}")
|
|
||||||
SPCD_PM_HTTPS_PATH="/etc/apt/apt.conf.d/https"
|
|
||||||
SPCD_PM_HTTPS_TEXT="\
|
|
||||||
Acquire::https::Verify-Peer False;
|
|
||||||
"
|
|
||||||
;;
|
|
||||||
"${SPCD_PM_ZYPPER}")
|
|
||||||
SPCD_PM_HTTPS_PATH=""
|
|
||||||
SPCD_PM_HTTPS_TEXT="\
|
|
||||||
"
|
|
||||||
;;
|
|
||||||
*) ;;
|
|
||||||
esac
|
|
||||||
spcd_split
|
|
||||||
spcd_os_printenv "SPCD_PM_HTTPS_PATH"
|
|
||||||
# specific
|
# specific
|
||||||
case "${SPCD_OS_ID}" in
|
case "${SPCD_OS_ID}" in
|
||||||
"${SPCD_OS_ALMA}")
|
"${SPCD_OS_ALMA}")
|
||||||
|
@ -968,8 +933,28 @@ Dir::Etc::SourceParts \"\";
|
||||||
spcd_packages_trust_https() {
|
spcd_packages_trust_https() {
|
||||||
spcd_step "Trust HTTPS"
|
spcd_step "Trust HTTPS"
|
||||||
if [ -n "${SPCD_CA_1}" ] || [ "${SPCD_PM}" = "${SPCD_PM_APT}" ]; then
|
if [ -n "${SPCD_CA_1}" ] || [ "${SPCD_PM}" = "${SPCD_PM_APT}" ]; then
|
||||||
spcd_os_mkdir "$(dirname "${SPCD_PM_HTTPS_PATH}")"
|
spcd_pth__path="$(spcd_https_path)"
|
||||||
spcd_os_write "${SPCD_PM_HTTPS_PATH}" "${SPCD_PM_HTTPS_TEXT}"
|
if [ -n "${spcd_pth__path}" ]; then
|
||||||
|
spcd_os_mkdir "$(dirname "${spcd_pth__path}")"
|
||||||
|
case "${SPCD_PM}" in
|
||||||
|
"${SPCD_PM_APK}") spcd_pth__text="\
|
||||||
|
--no-verify
|
||||||
|
" ;;
|
||||||
|
"${SPCD_PM_APT}") spcd_pth__text="\
|
||||||
|
Acquire::https::Verify-Peer False;
|
||||||
|
" ;;
|
||||||
|
"${SPCD_PM_DNF}") spcd_pth__text="\
|
||||||
|
sslverify=False
|
||||||
|
" ;;
|
||||||
|
"${SPCD_PM_PACMAN}") spcd_pth__text="\
|
||||||
|
SSLVerify = No
|
||||||
|
" ;;
|
||||||
|
"${SPCD_PM_ZYPPER}") ;;
|
||||||
|
*) ;;
|
||||||
|
esac
|
||||||
|
[ -n "${spcd_pth__text}" ] &&
|
||||||
|
spcd_os_write "${spcd_pth__path}" "${spcd_pth__text}"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue