mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
install: custom mongodb version selection
This commit is contained in:
1 parent
97e282d3ca
commit
f089ee1b09
1 file changed
+3
-2
+3
-2
@@ -115,6 +115,7 @@ for (const line of lines) {
|
|||||||
}
|
}
|
||||||
if (!['ubuntu', 'arch'].includes(values.id)) log.fatal('error.unsupportedOS', values.id);
|
if (!['ubuntu', 'arch'].includes(values.id)) log.fatal('error.unsupportedOS', values.id);
|
||||||
const Arch = values.id === 'arch';
|
const Arch = values.id === 'arch';
|
||||||
|
const mongodbVersion = __env.MONGODB_VERSION || '5.0';
|
||||||
let migration;
|
let migration;
|
||||||
|
|
||||||
const steps = [
|
const steps = [
|
||||||
@@ -162,9 +163,9 @@ const steps = [
|
|||||||
: [
|
: [
|
||||||
// https://letsencrypt.org/docs/dst-root-ca-x3-expiration-september-2021/
|
// https://letsencrypt.org/docs/dst-root-ca-x3-expiration-september-2021/
|
||||||
['apt-get upgrade openssl ca-certificates -y', { retry: true }],
|
['apt-get upgrade openssl ca-certificates -y', { retry: true }],
|
||||||
['wget -qO - https://www.mongodb.org/static/pgp/server-5.0.asc | apt-key add -', { retry: true }],
|
[`wget -qO - https://www.mongodb.org/static/pgp/server-${mongodbVersion}.asc | apt-key add -`, { retry: true }],
|
||||||
[`echo "deb ${getMirror('mongodb')} ${values.ubuntu_codename}\
|
[`echo "deb ${getMirror('mongodb')} ${values.ubuntu_codename}\
|
||||||
/mongodb-org/5.0 multiverse" >/etc/apt/sources.list.d/mongodb-org-5.0.list && \
|
/mongodb-org/${mongodbVersion} multiverse" >/etc/apt/sources.list.d/mongodb-org-${mongodbVersion}.list && \
|
||||||
apt-get -qq update && apt-get -q install -y mongodb-org`, { retry: true }],
|
apt-get -qq update && apt-get -q install -y mongodb-org`, { retry: true }],
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in new issue
Block a user