#17 docker-compose.yml, include script creare bază de date la instanțiere

state: closed opened by: adrianharabula on: 4/18/2017

Comments


from: adrianharabula on: 4/19/2017

Creăm o nouă imagine oracle-Dockerfile:

FROM wnameless/oracle-xe-11g

ADD database_design/psgbd-etapa2/SqlScripts/00-init.sql /docker-entrypoint-initdb.d/
ADD database_design/psgbd-etapa2/SqlScripts/01-createTables.sql /docker-entrypoint-initdb.d/

Și o folosim în docker-compose.yml:

version: '3'

services:
   oracledb:
     build:
       context: .
       dockerfile: oracle-Dockerfile
     image: condr/databse
     restart: always
     ports:
      - "1521:1521"

volumes:

Când se va instanția pentru prima dată baza de date, se vor executa scripturile adăugate.


from: adrianharabula on: 4/19/2017

1192493af6e5bfee0e4c6a9b2de307d65763fe24

results matching ""

    No results matching ""