Student Tracker is a comprehensive Student Management System designed for schools to simplify student data management. It allows teachers to register students, store essential documents, generate reports, and more.
- Teacher Dashboard: Manage students, view statistics, and access all features from a central dashboard.
- Student Management: Register new students, edit existing student information, and view a list of all students.
- Document Management: Upload and manage student files such as documents, photos, and signatures.
- Certificate Generation:
- Generate Annual Report Cards in PDF format.
- Create and download Achievement Certificates.
- Issue Virtual ID Cards.
- AI Chat: An integrated AI chat feature to assist teachers.
- Secure Authentication: Secure login for teachers with password hashing.
- Backend: Node.js, Express.js
- Frontend: EJS (Embedded JavaScript templates), Tailwind CSS, Flowbite
- Database: MySQL (using the
mysql2library) - Authentication: JWT (JSON Web Tokens) stored in cookies.
- File Handling:
pdf-libfor PDF generation,multerfor file uploads. - Security:
helmetfor securing HTTP headers,express-rate-limitfor rate limiting, and dynamic CSP nonces to prevent XSS attacks.
- Node.js (v18 or later)
- Docker and Docker Compose
-
Clone the repository:
git clone https://github.com/CodeByAmrit/school.git cd school -
Install dependencies:
npm install
-
Set up environment variables:
Create a
.envfile in the root of the project and add the following variables:DB_HOST=your-database-host DB_USER=your-database-user DB_PASSWORD=your-database-password DB_DATABASE=your-database-name DB_PORT=your-database-port JWT_SECRET=your-jwt-secret EMAIL_ID=your-email-address EMAIL_PASSWORD=your-email-password
-
Run the application:
npm run dev
The server will start in development mode with nodemon at
http://localhost:4000.
This project is fully containerized and can be run using Docker.
The easiest way to run the application in a production-like environment is with docker-compose.
-
Start the service:
docker-compose up
This will use the pre-built image
codebyamrit/student-trackerfrom Docker Hub. The application will be available athttp://localhost:8080.
You can also build the Docker image from the source code.
-
Build the image:
docker build -t your-dockerhub-username/student-tracker . -
Run the container:
docker run -d -p 8080:5000 --name student-tracker your-dockerhub-username/student-tracker
This project uses GitHub Actions for continuous integration and deployment.
- Workflow:
.github/workflows/docker-image.yml - Trigger: The workflow is triggered on every
pushto thecreate-docker-imagebranch. - Action: It builds a new Docker image and pushes it to Docker Hub with the tags
latestand a build number (e.g.,123).
This setup automates the process of creating a new Docker image whenever changes are pushed to the specified branch, ensuring that the latest version of the application is always ready for deployment.
This project is licensed under the ISC License. See the LICENSE file for details.