diff --git a/db-config/init.sql b/db-config/init.sql index 0ab903e..a2360cf 100644 --- a/db-config/init.sql +++ b/db-config/init.sql @@ -1,12 +1,14 @@ -- create a table -CREATE TABLE test( - id INT PRIMARY KEY GENERATED ALWAYS AS IDENTITY, - name TEXT NOT NULL, - archived BOOLEAN NOT NULL DEFAULT FALSE +CREATE TABLE ALUMNOS ( + id_alumno INT PRIMARY KEY GENERATED ALWAYS AS IDENTITY, + nombre TEXT NOT NULL, + apellido1 TEXT, + apellido2 TEXT, + email TEXT NOT NULL ); -- add test data -INSERT INTO test (name, archived) - VALUES ('test row 1', true), - ('test row 2', false); +INSERT INTO ALUMNOS (nombre, apellido1, apellido2, email) + VALUES ('Raúl', 'Bulgariu', 'Suciu', 'raul@bulgariu.xyz'), + ('Pepito', 'Prueba', 'de Ejemplo', 'pepito@gmail.com'); diff --git a/sample-config/drahoot.toml b/sample-config/drahoot.toml index 23482d7..83c123d 100644 --- a/sample-config/drahoot.toml +++ b/sample-config/drahoot.toml @@ -1,3 +1,7 @@ [Server] -# Port to use for web interface -#Port = "8080" +Port = "8080" +DB_Host = "127.0.0.1" +DB_Port = "5432" +DB_User = "drahootuser" +DB_Pass = "drahootpass" +DB_Name = "drahoot"