1.

What is docker-compose?

Answer»

Compose is a tool provided by DOCKER for defining and RUNNING multi-container applications together in an isolated ENVIRONMENT. Either a YAML or JSON file can be used to configure all the required services like Database, Messaging Queue along with the application server. Then, with a single command, we can CREATE and start all the services from the configuration file.

It comes handy to reproduce the entire application along with its services in various environments like development, testing, staging and most importantly in CI as well.

Typically the configuration file is named as docker-compose.yml. Below is a sample file:

version: '3' services:   app:     image: appName:latest     build: .     ports:               - "8080"        depends_on:       - oracledb     restart: on-failure:10       oracledb:     image: db:latest      volumes:       - /opt/oracle/oradata     ports:              - "1521"


Discussion

No Comment Found