A modern full-stack task management application featuring:
- Backend: Spring Boot (Java 17) with JWT authentication, H2 database, and Spring Security
- Frontend: Angular 17 with PrimeNG UI components and responsive design
- Deployment: Docker Compose for containerized development and deployment
git clone https://github.com/zfir-dev/SpringAngTasks.git
cd SpringAngTasks
docker-compose up --build
Once running, access the application:
- Frontend (Angular) → http://localhost:4200
- Backend API → http://localhost:8081
The backend exposes the H2 console at: http://localhost:8081/h2 with
- JDBC URL: jdbc:h2:mem:taskdb
- Username: sa
- Password: (empty)
- Open http://localhost:4200 in your browser.
- Register a new user or log in with existing credentials.
- Once logged in, you'll see the task dashboard where you can:
- Create new tasks
- View your tasks
- Update task status (Pending → Completed)
- Delete tasks
Once the backend is running, you can test it using the following commands.
curl -X POST http://localhost:8081/auth/register \
-H "Content-Type: application/json" \
-d '{"username":"zafir","password":"pass123"}'
TOKEN=$(curl -s -X POST http://localhost:8081/auth/login \
-H "Content-Type: application/json" \
-d '{"username":"zafir","password":"pass123"}' | jq -r .token)
echo $TOKEN
curl -X POST http://localhost:8081/api/tasks \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"title":"Deploy the app","description":"Using Docker Compose"}'
curl -X GET http://localhost:8081/api/tasks \
-H "Authorization: Bearer $TOKEN"
curl -X GET http://localhost:8081/api/tasks/1 \
-H "Authorization: Bearer $TOKEN"
curl -X PUT http://localhost:8081/api/tasks/1 \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"title":"Deploy backend","description":"Spring Boot on Docker","status":"COMPLETED"}'
curl -X DELETE http://localhost:8081/api/tasks/1 \
-H "Authorization: Bearer $TOKEN"
- Export your token after login so you don't have to copy-paste it:
TOKEN=$(curl -s -X POST http://localhost:8081/auth/login \
-H "Content-Type: application/json" \
-d '{"username":"zafir","password":"pass123"}' | jq -r .token)
- Use jq to pretty-print JSON responses:
curl -s -X GET http://localhost:8081/api/tasks -H "Authorization: Bearer $TOKEN" | jq