diff --git a/README.md b/README.md index ba62c5aac5e24a6ca8b272cf82324cb21b99313a..49821c7abc8dd8f0d55ff2b942e20380df419583 100644 --- a/README.md +++ b/README.md @@ -13,11 +13,27 @@ Location, size, and type of electricity generation plants and transmission lines ## Use -1. Pull the image: -> docker pull registry.git.nilu.no/fact/data/fact_power:latest - -2. Run this data service: ->docker run -t -i --name fact_power -e MARIADB_DATABASE=FACT_power -e MYSQL_ROOT_PASSWORD=devops -p 3313:3306 -d registry.git.nilu.no/fact/data/fact_power:latest +1. Through the command line: +```bash +docker pull registry.git.nilu.no/fact/data/fact_power:latest +docker run -t -i --name fact_power -e MARIADB_DATABASE=FACT_power -e MYSQL_ROOT_PASSWORD=devops -p 3313:3306 -d registry.git.nilu.no/fact/data/fact_power:latest +``` +2. Through a docker-compose file: +```yaml +version: '3.8' + +services: + fact_power: + image: registry.git.nilu.no/fact/data/fact_power:latest + container_name: fact_power + environment: + MARIADB_DATABASE: FACT_power + MYSQL_ROOT_PASSWORD: devops + ports: + - "3313:3306" + restart: unless-stopped +``` +which could be executed with `docker-compose up fact_power -d`. The container makes available a MariaDB instance with the full database on population **FACT_power**. It is reachable on port 3313 of the localhost and the root password is 'devops'.