Docker Compose is a tool for defining and running multi-container Docker applications. It allows you to define your application's services, networks, and volumes in a single file, called a 'docker-compose.yml' file, and then start and stop all services from this file. This simplifies the process of managing complex applications, as you can define all aspects of your application in one place.
Working with Docker Compose
Quick Tip
You can hover over the Visual Studio Code Terminal example below to make a Copy button
appear on the right hand side. Go ahead and try it now. Then just click the Copy button to copy the command and paste
it into the terminal to
bring up the file in your VSCode editor to make changes to the file. This functionality will be available in many of the
tasks throughout this lab.
Run the
docker-compose.yml file via the below command.
docker-compose up
Bash
Step 3 - Confirm The Containers Have Started Correctly
Check Docker Compoes Output
If the output is not similar to the below output, please notifiy the lab instructor
➜ DEVWKS-2135 ✗ |docker-compose up
[+] Running 2/0
⠿ Container yangsuite Created 0.0s
⠿ Container nginx Created 0.0s
Attaching to nginx, yangsuite
nginx | /docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
nginx | /docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
nginx | /docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh
nginx |10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist
nginx | /docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh
nginx | /docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh
nginx | /docker-entrypoint.sh: Configuration complete; ready for start up
yangsuite | /usr/local/lib/python3.6/dist-packages/ysdevices/utilities.py:4: CryptographyDeprecationWarning: Python 3.6 is no longer supported by the Python core team. Therefore, support for it is deprecated in cryptography. The next release of cryptography (40.0) will be the last to support Python 3.6.
yangsuite | from cryptography.fernet import Fernet
yangsuite |2023-02-02 11:25:34,475 - yangsuite.ysgnmi.gnmi: WARNING: Install yangsuite-testmanager for opfield verification
yangsuite |