Fix MongoDB repo verification and component setup
Simplifies the arguments passed to verify_repo_available by removing the MongoDB version and org path from the suite parameter. Also sets the repository component to 'main' instead of using the variable REPO_COMPONENT.
This commit is contained in:
parent
55120ae165
commit
e6bd1b5759
@ -2405,10 +2405,10 @@ function setup_mongodb() {
|
|||||||
esac
|
esac
|
||||||
|
|
||||||
# Verify the repository is available
|
# Verify the repository is available
|
||||||
if ! verify_repo_available "$MONGO_BASE_URL" "${SUITE}/mongodb-org/${MONGO_VERSION}"; then
|
if ! verify_repo_available "$MONGO_BASE_URL" "$SUITE"; then
|
||||||
msg_warn "MongoDB repo not available for ${DISTRO_ID}-${SUITE}, trying bookworm fallback"
|
msg_warn "MongoDB repo not available for ${DISTRO_ID}-${SUITE}, trying bookworm fallback"
|
||||||
SUITE="bookworm"
|
SUITE="bookworm"
|
||||||
if ! verify_repo_available "$MONGO_BASE_URL" "${SUITE}/mongodb-org/${MONGO_VERSION}"; then
|
if ! verify_repo_available "$MONGO_BASE_URL" "$SUITE"; then
|
||||||
msg_error "MongoDB repository not available for ${DISTRO_ID}-${DISTRO_CODENAME} (tried ${DISTRO_CODENAME} and bookworm)"
|
msg_error "MongoDB repository not available for ${DISTRO_ID}-${DISTRO_CODENAME} (tried ${DISTRO_CODENAME} and bookworm)"
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
@ -2425,7 +2425,7 @@ function setup_mongodb() {
|
|||||||
Types: deb
|
Types: deb
|
||||||
URIs: ${MONGO_BASE_URL}
|
URIs: ${MONGO_BASE_URL}
|
||||||
Suites: ${SUITE}/mongodb-org/${MONGO_VERSION}
|
Suites: ${SUITE}/mongodb-org/${MONGO_VERSION}
|
||||||
Components: ${REPO_COMPONENT}
|
Components: main
|
||||||
Architectures: amd64 arm64
|
Architectures: amd64 arm64
|
||||||
Signed-By: /etc/apt/keyrings/mongodb-${MONGO_VERSION}.gpg
|
Signed-By: /etc/apt/keyrings/mongodb-${MONGO_VERSION}.gpg
|
||||||
EOF
|
EOF
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user