mirror of https://github.com/docker/docs.git
Merge pull request #13639 from docker/master
Publish updates from master
This commit is contained in:
commit
fde650c3c8
|
|
@ -183,7 +183,7 @@ on:
|
|||
```
|
||||
{% endraw %}
|
||||
|
||||
This ensures that the main CI will only trigger if we tag our commits with `V.n.n.n.` Let’s test this. For example, run the following command:
|
||||
This ensures that the main CI will only trigger if we tag our commits with something like `v1.0.2` Let’s test this. For example, run the following command:
|
||||
|
||||
```console
|
||||
$ git tag -a v1.0.2
|
||||
|
|
@ -228,7 +228,7 @@ Remember to change how the image is tagged. The following example keeps ‘lates
|
|||
|
||||
{:width="500px"}
|
||||
|
||||
Now, we will have two different flows: one for our changes to master, and one for our pull requests. Next, we need to modify what we had before to ensure we are pushing our PRs to the GitHub registry rather than to Docker Hub.
|
||||
Now, we will have two different flows: one for our changes to master, and one for our pushed tags. Next, we need to modify what we had before to ensure we are pushing our PRs to the GitHub registry rather than to Docker Hub.
|
||||
|
||||
## Conclusion
|
||||
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ from the [project release page](https://github.com/docker/compose/releases){:tar
|
|||
3. Test your installation
|
||||
|
||||
```console
|
||||
$ docker compose --version
|
||||
$ docker compose version
|
||||
Docker Compose version 2.0.0
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -107,41 +107,12 @@ from the repository.
|
|||
> `BunsenLabs Linux Helium`, you could use `stretch`. Docker does not offer any guarantees on untested
|
||||
> and unsupported Debian distributions.
|
||||
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a data-toggle="tab" data-target="#x86_64_repo">x86_64 / amd64</a></li>
|
||||
<li><a data-toggle="tab" data-target="#armhf_repo">armhf</a></li>
|
||||
<li><a data-toggle="tab" data-target="#arm64_repo">arm64</a></li>
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
<div id="x86_64_repo" class="tab-pane fade in active" markdown="1">
|
||||
|
||||
```console
|
||||
$ echo \
|
||||
"deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
"deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
```
|
||||
|
||||
</div>
|
||||
<div id="armhf_repo" class="tab-pane fade" markdown="1">
|
||||
|
||||
```console
|
||||
$ echo \
|
||||
"deb [arch=armhf signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
```
|
||||
|
||||
</div>
|
||||
<div id="arm64_repo" class="tab-pane fade" markdown="1">
|
||||
|
||||
```console
|
||||
$ echo \
|
||||
"deb [arch=arm64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
```
|
||||
|
||||
</div>
|
||||
</div> <!-- tab-content -->
|
||||
|
||||
#### Install Docker Engine
|
||||
|
||||
This procedure works for Debian on `x86_64` / `amd64`, `armhf`, `arm64`, and Raspbian.
|
||||
|
|
|
|||
|
|
@ -124,51 +124,12 @@ from the repository.
|
|||
> `Linux Mint Tessa`, you could use `bionic`. Docker does not offer any guarantees on untested
|
||||
> and unsupported Ubuntu distributions.
|
||||
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a data-toggle="tab" data-target="#x86_64_repo">x86_64 / amd64</a></li>
|
||||
<li><a data-toggle="tab" data-target="#armhf_repo">armhf</a></li>
|
||||
<li><a data-toggle="tab" data-target="#arm64_repo">arm64</a></li>
|
||||
<li><a data-toggle="tab" data-target="#s390x_repo">s390x</a></li>
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
<div id="x86_64_repo" class="tab-pane fade in active" markdown="1">
|
||||
|
||||
```console
|
||||
$ echo \
|
||||
"deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
"deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
```
|
||||
|
||||
</div>
|
||||
<div id="armhf_repo" class="tab-pane fade" markdown="1">
|
||||
|
||||
```console
|
||||
$ echo \
|
||||
"deb [arch=armhf signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
```
|
||||
|
||||
</div>
|
||||
<div id="arm64_repo" class="tab-pane fade" markdown="1">
|
||||
|
||||
```console
|
||||
$ echo \
|
||||
"deb [arch=arm64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
```
|
||||
|
||||
</div>
|
||||
<div id="s390x_repo" class="tab-pane fade" markdown="1">
|
||||
|
||||
```console
|
||||
$ echo \
|
||||
"deb [arch=s390x signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] {{ download-url-base }} \
|
||||
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
```
|
||||
|
||||
</div>
|
||||
</div> <!-- tab-content -->
|
||||
|
||||
#### Install Docker Engine
|
||||
|
||||
1. Update the `apt` package index, and install the _latest version_ of Docker
|
||||
|
|
|
|||
|
|
@ -17,9 +17,7 @@ registry. The default registry is Docker Hub and is where all of the images we'v
|
|||
|
||||
To push an image, we first need to create a repository on Docker Hub.
|
||||
|
||||
1. [Sign up](https://www.docker.com/pricing?utm_source=docker&utm_medium=webreferral&utm_campaign=docs_driven_upgrade){:target="_blank" rel="noopener" class="_"} and share images using Docker Hub.
|
||||
|
||||
2. Sign in to [Docker Hub](https://hub.docker.com){:target="_blank" rel="noopener" class="_"}.
|
||||
1. [Sign up](https://www.docker.com/pricing?utm_source=docker&utm_medium=webreferral&utm_campaign=docs_driven_upgrade){:target="_blank" rel="noopener" class="_"} or Sign in to [Docker Hub](https://hub.docker.com){:target="_blank" rel="noopener" class="_"}.
|
||||
|
||||
2. Click the **Create Repository** button.
|
||||
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ So, let's do it!
|
|||
If you are using PowerShell then use this command:
|
||||
|
||||
```powershell
|
||||
docker run -dp 3000:3000 `
|
||||
PS> docker run -dp 3000:3000 `
|
||||
-w /app -v "$(pwd):/app" `
|
||||
node:12-alpine `
|
||||
sh -c "yarn install && yarn run dev"
|
||||
|
|
|
|||
|
|
@ -65,10 +65,10 @@ $ docker run -dp 3000:3000 \
|
|||
sh -c "yarn install && yarn run dev"
|
||||
```
|
||||
|
||||
If you are using PowerShell then use this command.
|
||||
If you are using PowerShell then use this command:
|
||||
|
||||
```powershell
|
||||
docker run -dp 3000:3000 `
|
||||
PS> docker run -dp 3000:3000 `
|
||||
-w /app -v "$(pwd):/app" `
|
||||
--network todo-app `
|
||||
-e MYSQL_HOST=mysql `
|
||||
|
|
@ -171,10 +171,10 @@ $ docker run -d \
|
|||
mysql:5.7
|
||||
```
|
||||
|
||||
If you are using PowerShell then use this command.
|
||||
If you are using PowerShell then use this command:
|
||||
|
||||
```powershell
|
||||
docker run -d `
|
||||
PS> docker run -d `
|
||||
--network todo-app --network-alias mysql `
|
||||
-v todo-mysql-data:/var/lib/mysql `
|
||||
-e MYSQL_ROOT_PASSWORD=secret `
|
||||
|
|
|
|||
|
|
@ -95,8 +95,8 @@ All containers in Kubernetes are scheduled as _pods_, which are groups of co-loc
|
|||
if all is well, your deployment should be listed as follows:
|
||||
|
||||
```shell
|
||||
NAME DESIRED CURRENT UP-TO-DATE AVAILABLE AGE
|
||||
bb-demo 1 1 1 1 48s
|
||||
NAME READY UP-TO-DATE AVAILABLE AGE
|
||||
bb-demo 1/1 1 1 40s
|
||||
```
|
||||
|
||||
This indicates all one of the pods you asked for in your YAML are up and running. Do the same check for your services:
|
||||
|
|
|
|||
|
|
@ -32,9 +32,7 @@ Let’s open a new terminal then make a GET request to the server using the curl
|
|||
$ curl --request POST \
|
||||
--url http://localhost:8000/test \
|
||||
--header 'content-type: application/json' \
|
||||
--data '{
|
||||
"msg": "testing"
|
||||
}'
|
||||
--data '{"msg": "testing"}'
|
||||
curl: (7) Failed to connect to localhost port 8000: Connection refused
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ Let’s create a simple Python application using the Flask framework that we’l
|
|||
```console
|
||||
$ cd /path/to/python-docker
|
||||
$ pip3 install Flask
|
||||
$ pip3 freeze > requirements.txt
|
||||
$ pip3 freeze | grep Flask >> requirements.txt
|
||||
$ touch app.py
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -147,7 +147,7 @@ First, let’s add the `mysql-connector-python` module to our application using
|
|||
|
||||
```console
|
||||
$ pip3 install mysql-connector-python
|
||||
$ pip3 freeze > requirements.txt
|
||||
$ pip3 freeze | grep mysql-connector-python >> requirements.txt
|
||||
```
|
||||
|
||||
Now we can build our image.
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ If you need to specify volume driver options, you must use `--mount`.
|
|||
is mounted in the container. May be specified as `destination`, `dst`,
|
||||
or `target`.
|
||||
- The `readonly` option, if present, causes the bind mount to be [mounted into
|
||||
the container as read-only](#use-a-read-only-volume).
|
||||
the container as read-only](#use-a-read-only-volume). May be specified as `readonly` or `ro`.
|
||||
- The `volume-opt` option, which can be specified more than once, takes a
|
||||
key-value pair consisting of the option name and its value.
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue