From a8ae5f14d48adf44c71e7c575e73f62d0858131b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Th=C3=A9o=20Le=20Lez?= Date: Wed, 12 Feb 2025 11:09:17 +0100 Subject: [PATCH] fix: db connection --- MyINPulse-back/src/main/resources/application.properties | 7 ++++--- MyINPulse-back/src/main/resources/data.sql | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/MyINPulse-back/src/main/resources/application.properties b/MyINPulse-back/src/main/resources/application.properties index b53191b..e67e4f6 100644 --- a/MyINPulse-back/src/main/resources/application.properties +++ b/MyINPulse-back/src/main/resources/application.properties @@ -2,9 +2,10 @@ spring.application.name=myinpulse spring.security.oauth2.resourceserver.jwt.jwk-set-uri=http://localhost:7080/realms/test/protocol/openid-connect/certs spring.security.oauth2.resourceserver.jwt.issuer-uri=http://localhost:7080/realms/test logging.level.org.springframework.security=DEBUG -spring.datasource.url=jdbc:postgresql://postgres/${POSTGRES_DB} -spring.datasource.username=${POSTGRES_USER} -spring.datasource.password=${POSTGRES_PASSWORD} +#spring.datasource.url=jdbc:postgresql://postgres/${POSTGRES_DB} +spring.datasource.url=jdbc:postgresql://localhost:5433/backend_db +spring.datasource.username=backend_db_user +spring.datasource.password=backend_db_user_password spring.jpa.hibernate.ddl-auto=update spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect diff --git a/MyINPulse-back/src/main/resources/data.sql b/MyINPulse-back/src/main/resources/data.sql index bd0f49a..4014267 100644 --- a/MyINPulse-back/src/main/resources/data.sql +++ b/MyINPulse-back/src/main/resources/data.sql @@ -4,7 +4,7 @@ INSERT INTO projets (nom_projet, logo, date_creation, status_projet) VALUES ('Débat concours', decode('022024abd5486e245c145dda65116f', 'hex'), TO_DATE('22-NOV-2023', 'DD-MON-YYYY'), 'Suspendu'), ('HDeirbMI', decode('ab548d6c1d595a2975e6476f544d14c55a', 'hex'), TO_DATE('07-DEC-2024', 'DD-MON-YYYY'), 'Lancement'); -INSERT INTO utilisateurs (nom, prenom, mail_principal, mail_secondaire, numero_telephone) VALUES +INSERT INTO utilisateurs (nom_utilisateur, prenom_utilisateur, mail_principal, mail_secondaire, numero_telephone) VALUES ('Dupont', 'Dupond', 'super@mail.fr', 'super2@mail.fr', '06 45 72 45 98'), ('Martin', 'Matin', 'genial@mail.fr', 'genial2@mail.fr', '06 52 14 58 73'), ('Charvet', 'Lautre', 'mieux@tmail.fr', 'mieux2@tmail.fr', '07 49 82 16 35'),