Updated API authentication using Spring Security.
- Gradle 8.14.2
- Java 24
Supports direct run with H2 DB or docker compose with PostgresSQL.
- Created a
.envfile:
DB_URL=jdbc:postgresql://postgresql:5432/postgres
DB_USER=postgres
DB_PASSWORD=password
DB_DRIVER=org.postgresql.Driver
HIBERNATE_DIALECT=org.hibernate.dialect.PostgreSQLDialect
HOST_IP=localhost
HOST_PORT=8080
- Run
docker compose up -d
By default, it will use the .env.test file (H2 DB).
./gradlew bootRunIf you want to use a local PostgreSQL instance, update your .env with the IP of your DB. Run the project with the .env variables loaded.
Careful, H2 console is enabled.