Skip to content

End-to-end room booking & status display system for eNStudios. Features media queueing via FullCalendar, role-based access, and automated GitHub Actions deployments with built-in security audits.

License

Notifications You must be signed in to change notification settings

MaxPolak04/tab_view

Repository files navigation

TabView System

Project Version Python Flask Docker License CI/CD

πŸ“Œ About the Project

TabView is a dedicated web platform created for eNStudios to centrally manage information tablets (Room Booking / Status Display). The system solves the problem of manually updating conference room statuses and display devices.

The project was delivered in an end-to-end model: from client problem analysis, through architecture and development, to setting up CI/CD pipelines and production deployment.


TabView Dashboard

Key Features

  • Resource Management: Full CRUD for Users, Media, and Devices.
  • Interactive Schedule: Media display queue management via FullCalendar.io interface, integrated with the API (Flask-RESTful).
  • Media Queueing: Precise sequencing of photos and videos displayed on tablets.
  • Role System: Permission separation (Admin / User).
  • Interface: Responsive UI based on Jinja2 templates and Bootstrap (Dark/Light mode).

πŸ— Architecture & Tech Stack

The project relies on a modern Python stack with a focus on performance and stability.

Backend & Data

  • Language: Python 3.12
  • Framework: Flask Ecosystem (Blueprints, Application Factory Pattern, Flask-RESTful).
  • Database: MySQL (persistent data storage).
  • Cache & Queues: Redis (session caching, rate limiter handling).
  • Package Management: uv – a modern, ultra-fast Python package manager.
  • Background Tasks: APScheduler (handling cyclic system tasks).

Frontend

  • Rendering: Server-Side Rendering (SSR) using Jinja2.
  • UI/UX: Bootstrap + FullCalendar.io + custom JavaScript.

πŸš€ DevOps & Infrastructure

This project places special emphasis on Infrastructure as Code (IaC) and full containerization to ensure environment reproducibility (Development vs. Production).

Containerization & Deployment

The entire application is containerized using Docker. The architecture consists of the following services defined in docker-compose.yml:

  1. NginX (Reverse Proxy): Runs on port 80, handles incoming traffic, and serves static files.
  2. Web (Gunicorn): WSGI application server running on internal port 8000.
  3. Database (MySQL): Available on port 3306.
  4. Redis: Available on port 6379.

CI/CD Pipeline (GitHub Actions)

An advanced pipeline has been implemented to automate the software delivery process:

  • Build: Building Docker images.
  • Registry: Automatically pushing built images to GHCR (GitHub Container Registry).
  • Testing: Running unit and integration tests before every merge.

πŸ›‘οΈ Security

The approach to security in TabView is twofold: security built into the application (App Security) and automatic audits in the development process (DevSecOps).

1. Application Security (Runtime)

Features protecting the running application in production:

  • SQL Injection Protection: Utilizing SQLAlchemy ORM for query parameterization.
  • CSRF Protection: All forms protected by tokens generated by Flask-WTF.
  • Rate Limiting: Protecting the API against Brute-Force and DDoS attacks using Flask-Limiter (storage in Redis).
  • Secure Passwords: Hashing with rainbow-table resistant algorithms.
  • Error Hardening: The application does not leak stack traces in HTTP responses (generic error pages).

2. DevSecOps & Code Quality (Pipeline)

A set of tools triggered automatically in GitHub Actions and as pre-commit hooks, preventing the deployment of insecure code:

  • Vulnerability Scanning (SCA): pip-audit checks dependencies for known security vulnerabilities (CVE).
  • Static Application Security Testing (SAST): bandit analyzes source code for insecure patterns (e.g., hardcoded secrets, use of eval).
  • Linting & Formatting: ruff enforces strict adherence to PEP-8 standards.
  • Tests: pytest with external service mocking.

βš™οΈ Installation & Setup

Requirements: Docker and Docker Compose.

  1. Clone the repository:
git clone https://github.com/MaxPolak04/tab_view.git
cd tab_view
  1. Configure environment variables: Create a .env file based on .env.example:
FLASK_APP=tab_view
SECRET_KEY=your-very-secret-key
DATABASE_URL=mysql+pymysql://user:pass@db/dbname
RATELIMIT_STORAGE_URI=redis://redis:6379
  1. Start the environment:
docker compose up -d --build
  1. The application will be available at: http://localhost:80

CLI - User Management

The project includes custom CLI commands. To create a user inside a running container:

# Syntax: flask create-user [user] [pass] --admin (optional)
docker compose exec web flask create-user john P@ssw0rd123 --admin

πŸ‘¨β€πŸ’» About the Author & Learning Journey

I am an aspiring Junior Developer, and TabView is a project I realized during my student internship at eNStudios.

Context: The application was created in a Client (IT Admin) – Contractor (Me) relationship. The company needed a dedicated solution but lacked the budget for commercial software or a Senior Developer to guide me. I had to fill this gap independently.

My Path and Challenges: As a one-person team, I had to step out of the programmer role and take full responsibility for the product:

  • Engineering over Coding: I didn't focus just on making the code "work", but on making it secure, maintainable, and resilient (e.g., handling backups, predicting production edge-cases).
  • Self-Education: I learned everything – from architecture to CI/CD – on the fly, researching user needs and verifying best practices in documentation and online resources.
  • Conscious AI Use: Artificial Intelligence was my mentor and reviewer (suggesting DevSecOps implementation, among other things), but never the "manager". I am not a "VibeCoder" – I verified every AI suggestion, and ultimately, I know and understand every line of code in this repository.

This project proved to me that I can deliver a complete, secure, and deployable solution, even under the pressure of limited resources and lack of mentorship.


πŸ“« Feedback & Contact

As a student and beginning software engineer, I have made every effort to ensure this project meets production standards and adheres to Best Practices.

However, I am aware there is always room for improvement. If you notice an area for optimization in the code, a bug, or have a suggestion regarding the architecture – your feedback is incredibly valuable to me.

Feel free to reach out via:


πŸ“„ License

This project is licensed under the Creative Commons Attribution-NonCommercial 4.0 International (CC BY-NC 4.0). See the LICENSE file for details.

About

End-to-end room booking & status display system for eNStudios. Features media queueing via FullCalendar, role-based access, and automated GitHub Actions deployments with built-in security audits.

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Packages