Différences
Ci-dessous, les différences entre deux révisions de la page.
Prochaine révision | Révision précédente | ||
elearning:workbooks:docker3:en:dre01 [2023/12/17 05:23] – created admin | elearning:workbooks:docker3:en:dre01 [2024/12/17 13:46] (Version actuelle) – admin | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
~~PDF: | ~~PDF: | ||
- | Version : **2023.01** | + | Version : **2024.01** |
Last update : ~~LASTMOD~~ | Last update : ~~LASTMOD~~ | ||
Ligne 111: | Ligne 111: | ||
* Jenkins. | * Jenkins. | ||
- | You can also create your own plugin. | + | You can also create your own plugins. |
====Docker CE and Docker EE==== | ====Docker CE and Docker EE==== | ||
Ligne 154: | Ligne 154: | ||
* **Basic** - (official Docker support (J) and certified containers and plugins), | * **Basic** - (official Docker support (J) and certified containers and plugins), | ||
* $1,500 per node per year (2022), | * $1,500 per node per year (2022), | ||
- | * Standard** - (Basic + advanced image and container management, support for user authentication via LDAP/AD, RBAC), | + | |
* $3,000 per node per year (2022), | * $3,000 per node per year (2022), | ||
- | * Advanced** - (Standard + security scanning and continuous vulnerability monitoring), | + | |
* $3,500 per node per year (2022). | * $3,500 per node per year (2022). | ||
Ligne 193: | Ligne 193: | ||
Please note that since the names of Docker packages have changed, you should uninstall any previous version of Docker before installing the current version: | Please note that since the names of Docker packages have changed, you should uninstall any previous version of Docker before installing the current version: | ||
- | For example under Debian and Ubuntu: | + | **For example** under Debian and Ubuntu: |
< | < | ||
Ligne 271: | Ligne 271: | ||
<WRAP center round important 50%> | <WRAP center round important 50%> | ||
- | **Important** - Note that the **lsb_release -cs** command returns the name of the Debian | + | **Important** - Note that the **lsb_release -cs** command returns the name of the Debian |
</ | </ | ||
Ligne 306: | Ligne 306: | ||
< | < | ||
root@debian11: | root@debian11: | ||
- | Client: Docker Engine - Community[root@centos8 ~]# yum remove podman | + | Client: Docker Engine - Community |
- | Dependencies resolved. | + | |
- | ====================================================================================== | + | |
- | | + | |
- | ====================================================================================== | + | |
- | Removing: | + | |
- | | + | |
- | Removing dependent packages: | + | |
- | | + | |
- | Removing unused dependencies: | + | |
- | | + | |
- | | + | |
- | + | ||
- | Transaction Summary | + | |
- | ====================================================================================== | + | |
- | Remove | + | |
- | + | ||
- | Freed space: 49 M | + | |
- | Is this ok [y/N]: y | + | |
- | Running transaction check | + | |
- | Transaction check succeeded. | + | |
- | Running transaction test | + | |
- | Transaction test succeeded. | + | |
- | Running transaction | + | |
- | Preparing | + | |
- | Running scriptlet: cockpit-podman-33-1.module_el8.5.0+890+6b136101.noarch | + | |
- | Erasing | + | |
- | Erasing | + | |
- | Running scriptlet: podman-3.3.1-9.module_el8.5.0+988+b1f0b741.x86_64 | + | |
- | Erasing | + | |
- | Erasing | + | |
- | Running scriptlet: conmon-2: | + | |
- | Verifying | + | |
- | Verifying | + | |
- | Verifying | + | |
- | Verifying | + | |
- | Installed products updated. | + | |
- | + | ||
- | Removed: | + | |
- | cockpit-podman-33-1.module_el8.5.0+890+6b136101.noarch | + | |
- | conmon-2: | + | |
- | podman-3.3.1-9.module_el8.5.0+988+b1f0b741.x86_64 | + | |
- | podman-catatonit-3.3.1-9.module_el8.5.0+988+b1f0b741.x86_64 | + | |
- | + | ||
- | Complete! | + | |
| | ||
API version: 1.43 | API version: 1.43 | ||
Ligne 588: | Ligne 544: | ||
Complete! | Complete! | ||
+ | </ | ||
+ | < | ||
[root@centos8 ~]# yum install docker-ce docker-ce-cli containerd.io --allowerasing | [root@centos8 ~]# yum install docker-ce docker-ce-cli containerd.io --allowerasing | ||
Last metadata expiration check: 0:05:43 ago on Fri 18 Aug 2023 16:04:20 CEST. | Last metadata expiration check: 0:05:43 ago on Fri 18 Aug 2023 16:04:20 CEST. | ||
Ligne 1229: | Ligne 1187: | ||
</ | </ | ||
- | ====1.5 - Deleting a Container | + | ====1.5 - Deleting a Container==== |
- | To remove a container | + | To remove a container, the **docker rm** command should be used, referencing the container either by its **NAME** or by its CONTAINER ID : |
< | < | ||
Ligne 1258: | Ligne 1216: | ||
====1.6 -Creating an Image from a Modified Container=== | ====1.6 -Creating an Image from a Modified Container=== | ||
- | Modifying an image container: | + | Modify the ubuntu |
< | < | ||
Ligne 1672: | Ligne 1630: | ||
====1.10 - Injecting Environment Variables into a Container==== | ====1.10 - Injecting Environment Variables into a Container==== | ||
- | To inject one or more environment variables into a container, use a pre-established | + | To inject one or more environment variables into a container, use a file: |
< | < | ||
Ligne 1706: | Ligne 1664: | ||
</ | </ | ||
- | =====1.12 - Mapping Ports of a Container===== | + | ====1.12 - Mapping Ports of a Container==== |
Start a nginx container on port localhost 81 : | Start a nginx container on port localhost 81 : | ||
Ligne 1729: | Ligne 1687: | ||
</ | </ | ||
- | Note that using ^C interrupted | + | Note that using ^C killed |
< | < | ||
Ligne 1831: | Ligne 1789: | ||
</ | </ | ||
- | ====.16 - Using Signals with a Container==== | + | ====1.16 - Using Signals with a Container==== |
Use a signal to kill the nginx container process: | Use a signal to kill the nginx container process: | ||
Ligne 1868: | Ligne 1826: | ||
</ | </ | ||
- | ====.17 - Force Delete a Running Container==== | + | ====1.17 - Force Delete a Running Container==== |
Delete a running container: | Delete a running container: | ||
Ligne 1896: | Ligne 1854: | ||
< | < | ||
+ | root@debian11: | ||
+ | |||
root@debian11: | root@debian11: | ||
Ligne 1923: | Ligne 1883: | ||
<WRAP center round important 50%> | <WRAP center round important 50%> | ||
- | **Important** - Note here the use of **ro** - read-only. | + | **Important** - Note here the use of **ro** |
</ | </ | ||
Ligne 2238: | Ligne 2198: | ||
</ | </ | ||
- | Start the container | + | Create another |
< | < | ||
Ligne 2435: | Ligne 2395: | ||
----- | ----- | ||
- | Copyright © 2023 Hugh Norris. | + | Copyright © 2024 Hugh Norris. |