@@ -4,28 +4,31 @@ level: 4
4
4
ref : import-key
5
5
content : |
6
6
From a terminal, issue the following command to import the
7
- MongoDB public GPG Key from `<https://www.mongodb.org/static/pgp/server-{+pgp-version+}.asc>`_:
7
+ MongoDB public GPG key from `<https://www.mongodb.org/static/pgp/server-{+pgp-version+}.asc>`_:
8
8
9
9
.. code-block:: sh
10
10
11
- wget -qO - https://www.mongodb.org/static/pgp/server-{+pgp-version+}.asc | sudo apt-key add -
11
+ wget -qO- https://www.mongodb.org/static/pgp/server-{+pgp-version+}.asc | sudo tee /etc/ apt/trusted.gpg.d/server-{+pgp-version+}.asc
12
12
13
- The operation should respond with an ``OK``.
13
+ The previous command writes the GPG key to your system's
14
+ ``/etc/apt/trusted.gpg.d`` folder and prints the key to your
15
+ terminal. You do not need to copy or save the key that is printed to
16
+ the terminal.
14
17
15
- However, if you receive an error indicating that ``gnupg`` is not
16
- installed, you can :
18
+ If you receive an error indicating that ``gnupg`` is not installed,
19
+ perform the following steps :
17
20
18
21
#. Install ``gnupg`` and its required libraries using the following command:
19
22
20
23
.. code-block:: sh
21
24
22
25
sudo apt-get install gnupg
23
26
24
- #. Once installed, retry importing the key:
27
+ #. Retry importing the key:
25
28
26
29
.. code-block:: sh
27
30
28
- wget -qO - https://www.mongodb.org/static/pgp/server-{+pgp-version+}.asc | sudo apt-key add -
31
+ wget -qO- https://www.mongodb.org/static/pgp/server-{+pgp-version+}.asc | sudo tee /etc/ apt/trusted.gpg.d/server-{+pgp-version+}.asc
29
32
---
30
33
title : Create a list file for MongoDB.
31
34
stepnum : 2
@@ -39,17 +42,32 @@ content: |
39
42
40
43
Click on the appropriate tab for your version of Ubuntu.
41
44
If you are unsure of what Ubuntu version the host is running,
42
- open a terminal or shell on the host and execute ``lsb_release -dc``.
45
+ open a terminal or shell on the host and run ``lsb_release -dc``.
43
46
44
47
.. tabs::
45
48
46
49
tabs:
50
+ - id: jammy
51
+ name: Ubuntu 22.04 (Jammy)
52
+ content: |
53
+
54
+ The following instruction is for **Ubuntu 22.04 (Jammy)**.
55
+ For other Ubuntu releases, click the appropriate tab.
56
+
57
+ Create the
58
+ ``/etc/apt/sources.list.d/mongodb-org-{+mdb-version+}.list``
59
+ file for Ubuntu 22.04 (Jammy):
60
+
61
+ .. code-block:: sh
62
+
63
+ echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu jammy/mongodb-org/{+mdb-version+} multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-{+mdb-version+}.list
64
+
47
65
- id: focal
48
66
name: Ubuntu 20.04 (Focal)
49
67
content: |
50
68
51
69
The following instruction is for **Ubuntu 20.04 (Focal)**.
52
- For Ubuntu 18.04 (Bionic) click on the appropriate tab.
70
+ For other Ubuntu releases, click the appropriate tab.
53
71
54
72
Create the
55
73
``/etc/apt/sources.list.d/mongodb-org-{+mdb-version+}.list``
@@ -64,7 +82,7 @@ content: |
64
82
content: |
65
83
66
84
The following instruction is for **Ubuntu 18.04
67
- (Bionic)**. For Ubuntu 20.04 (Focal) click on the
85
+ (Bionic)**. For other Ubuntu releases, click the
68
86
appropriate tab.
69
87
70
88
Create the
@@ -113,4 +131,20 @@ content: |
113
131
.. code-block:: sh
114
132
115
133
sudo apt-get install -y mongodb-mongosh-shared-openssl3
134
+ ---
135
+ title : Confirm that ``mongosh`` installed successfully.
136
+ stepnum : 5
137
+ level : 4
138
+ ref : confirm
139
+ content : |
140
+
141
+ To confirm that ``mongosh`` installed successfully, run the following
142
+ command:
143
+
144
+ .. code-block:: sh
145
+
146
+ mongosh --version
147
+
148
+ Your terminal should respond with the version of ``mongosh`` you have
149
+ installed.
116
150
...
0 commit comments