1. Offline installationhttps://github.com/docker/compose/releases Move files
Modify the file name
Grant execution permissions to docker-compose. By default, there is no execute permission.
Whether the test is successful
2. Online installationrun
Install a different version and modify the version number to 1.29.2. If you encounter curl problems, use pip to install
Without virtualenv implement
Grant execution permissions to docker-compose. By default, there is no execute permission. In /usr/local/bin
Whether the test is successful
3. Uninstall
Installed using pip
4. Define the yml file1. Download the nginx image
2. Write the docker-compose.yml file. Pay attention to the format of the YML file. version: '3' #version number services: #docker container nginx: #container name container_name: nginx-1 #customize the container name after startup restart: always #Set to always, indicating that this container should always restart when stopped image: nginx:latest #image name: version number ports: #startup port number - 4433:80 volumes: #Data volume, mapping files in the container to the server - ./conf.d:/etc/nginx/conf.d environment: #Environment configuration TZ: Asia/shanghai 3. Start. Under the yml file
This is the end of this article about docker-compose installation and yml file configuration. For more relevant docker-compose yml file configuration content, please search 123WORDPRESS.COM's previous articles or continue to browse the following related articles. I hope you will support 123WORDPRESS.COM in the future! You may also be interested in:
|
<<: Vue codemirror realizes the effect of online code compiler
>>: MySQL executes commands for external sql script files
1. Rendering JD Effect Simulation Effect 2. Princ...
Table of contents JS obtains the .txt file conten...
Preface Share two methods to monitor whether an e...
Table of contents Preface Main implementation cod...
Step 1: Install Stow In this example, we are usin...
Preface A requirement I had previously made, to s...
Table of contents Preface Computed properties Int...
This article introduces the installation of Windo...
Code first, then text Copy code The code is as fol...
Preface: After the automation is written, it need...
Preface: Due to my work, I am involved in the fie...
Preface In WeChat applet, you can use globalData ...
Today I got familiar with the mouse zooming effect...
Table of contents 1. Installation Environment 2. ...
List style properties There are 2 types of lists ...