Table of Contents
This repo contains a code to enter email for newsletter subscription service, the idea of this app is to add emails to mysql serve in the background. Any user(email) can be subscribed only once, if someone who is already subscribed to a newsletter is trying to subscribe again, a pop up will tell the user to contact customer care. This simple demo only simulates data entry and recovery from SQL into a front-end(streamlit).
This project is built with the below given major frameworks and libraries. The code is primarily based on python.
conda environment is ideal for creating environments with the right packages. Pip is required to install the dependencies.
Docker compose is the easiest way to run this. If not you will have to setup the mysql server along with
-
Clone the repository using
git clone https://github.com/sudharsan-007/newsletter_app.git
-
Run docker-compose
docker-compose up --build
-
Install pre-requisites Conda, pip, python, and mySQL and clone this repo
-
Comment out
db_config
for Docker (line ~20) and configure db_config based on your mysql setup (password, username and database variables) -
Install Dependencies in a conda environment
conda create -n "newsletter_app" python=3.8 conda activate newsletter_app python3 -m pip install -r requirements.txt
-
Run the app
streamlit run app.py
-
Play with the code and enjoy
Distributed under the MIT License. See LICENSE.txt
for more information.