change drop-and-create to update database

This commit is contained in:
Valentin CZERYBA 2022-09-25 22:49:03 +02:00
parent b3b9a612ef
commit 68da72fe55
2 changed files with 4 additions and 3 deletions

View File

@ -54,6 +54,7 @@ public class TokenRessource {
name = new String(Base64.decode(user), StandardCharsets.UTF_8);
}
} else {
String[] hash = new String(Base64.decode(auth.split(" ")[1]), StandardCharsets.UTF_8).split(":");
name = hash[0];
password = Hash.encryptSHA512(hash[1]);

View File

@ -11,8 +11,8 @@ quarkus.datasource.username = toto
quarkus.datasource.password = toto
quarkus.datasource.jdbc.url = jdbc:postgresql://db:5432/toto
# drop and create the database at startup (use `update` to only update the schema)
quarkus.hibernate-orm.database.generation = drop-and-create
#quarkus.hibernate-orm.database.generation = drop-and-create
quarkus.hibernate-orm.database.generation = update
covas.schema.create = true
quarkus.mailer.auth-methods=DIGEST-MD5 CRAM-SHA256 CRAM-SHA1 CRAM-MD5 PLAIN LOGIN
@ -31,4 +31,4 @@ quarkus.http.cors=true
quarkus.http.origins=http://localhost:8084
quarkus.http.cors.methods=GET,PUT,POST,DELETE,PATCH
quarkus.http.cors.headers=accept,authorization,content-type,x-requested-with,x-foobar
quarkus.http.cors.access-control-allow-credentials=true
quarkus.http.cors.access-control-allow-credentials=true