diff --git a/compose.yaml b/compose.yaml index 26d1ada..4db7aec 100644 --- a/compose.yaml +++ b/compose.yaml @@ -1,8 +1,6 @@ services: database: - image: pgsql:2025.09 - build: - context: ./pgsql + image: iut/pgsql:2025-08 environment: POSTGRES_INITDB_ARGS: "--locale-provider=icu --icu-locale=fr-FR" POSTGRES_DB: ${COMPOSE_PROJECT_NAME} @@ -10,8 +8,10 @@ services: POSTGRES_USER: ${COMPOSE_PROJECT_NAME} volumes: - database_data:/var/lib/postgresql/data:rw - - ./pgsql/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d - - ./pgsql/data:/tmp + - ./docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d + - ./data:/tmp + ports: + - 5432:5432 volumes: database_data: diff --git a/initdb.sql b/docker-entrypoint-initdb.d/initdb.sql similarity index 100% rename from initdb.sql rename to docker-entrypoint-initdb.d/initdb.sql diff --git a/exercice.md b/exercice.md index 46e9218..85fd751 100644 --- a/exercice.md +++ b/exercice.md @@ -12,6 +12,14 @@ Tickets : id_ticket, date_vente, id_client LignesTicket : id_ligne, id_ticket, id_produit, quantite, prix_unitaire +## Environnement + +### Construire l'image + +```shell +docker build -t iut/pgsql:2025-08 . +``` + ## Questions ### Exercice 1 : Nombre total de tickets