Overview • Features • Installation • Usage • License
This repository contains a social platform application with a frontend built using Streamlit and a backend using FastAPI, integrated with a Firebase database. The platform is designed to facilitate simple communication between the Streamlit system and the database through an API and to test the capabilities of Streamlit, which is known for its somewhat limited features.
- Streamlit Frontend: A user-friendly interface for interacting with the platform.
- FastAPI Backend: Robust API for efficient server-side processing.
- Firebase Database Integration: Cloud-based database for secure and scalable data storage.
The entire setup is containerized using Docker Compose, ensuring easy and consistent deployment.
- Docker
- Docker Compose
-
FastAPI Container Setup:
cd Fastapi docker build -t fastapi . docker run -d --name fastapi -p 8000:8000 fastapi
-
Streamlit Container Setup:
cd Streamlit docker build -t streamlit . docker run -d --name streamlit -p 8501:8501 streamlit
-
Docker Compose:
docker-compose build docker-compose up
To connect to Firebase:
- Create a config.py file in the main directory of the Streamlit app.
- Insert the firebaseConfig dictionary into config.py to establish a connection with the Firebase database.
The main frontend file (main.py in the Streamlit app directory) demonstrates the usage of various components such as authentication, database interactions, and UI elements.
- Firebase Authentication: User authentication via Firebase.
- Database Operations: CRUD operations with Firebase Realtime Database.
- Custom Component Builder: A utility for incorporating custom styles and scripts.\
This project is licensed under the MIT License - see the LICENSE file for details.