The Feedback Form project is an online platform that enables clients to provide valuable suggestions and reviews, fostering an interactive and user-driven improvement process. Built with Flask, MySQL, Celery, and Redis, all components are containerized in Docker, ensuring seamless communication between them.
- Project Overview
- Project Setup
- Build and Run
- Testing
- Initializing Database
- Test in Browser
- Contact
- License
The Feedback Form project serves as an online suggestion and review platform, allowing users to share their feedback and improve the overall user experience.
Before you begin, ensure you have met the following requirements:
- You have installed
Docker
andDocker Compose
. - You have a suitable text editor to edit .env and other files.
To install Feedback Form, follow these steps:
- Clone the repository.
- Set up your environment variables in the .env file:
Create a .env
file in the project root and set the following values:
# Email Configuration
MAIL_USERNAME='yourgmail@email.com'
MAIL_PASSWORD='google app password'
MAIL_DEFAULT_SENDER='yourgmail@email.com'
ADMIN_EMAIL='random@email.com'
# Database Configuration
DATABASE_URL='mysql+pymysql://feedback:yourpassword@mysql:3306/feedback_form'
MYSQL_ROOT_PASSWORD='yourpassword'
MYSQL_DATABASE='feedback_form'
MYSQL_USER='feedback'
MYSQL_PASSWORD='yourpassword'
These values will be used by the config/settings.py file
docker-compose up --build
docker-compose up
docker-compose stop
docker-compose exec website pytest feedback_form/tests
docker-compose exec website pytest --cov-report term-missing --cov feedback_form
Before testing code, database has to be initialized with the commands below in a different terminal
docker-compose exec website env FLASK_APP=feedback_form/app.py flask db init
docker-compose exec website env FLASK_APP=feedback_form/app.py flask db migrate
docker-compose exec website env FLASK_APP=feedback_form/app.py flask db upgrade
Visit localhost:8000 or 0.0.0.0:8000 in your web browser to test the application.
This project is licensed under the MIT License. See the LICENSE file for details.