Skip to content

Memomer/Fastapi-Social-Media-Backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Running FastAPI:

  1. Clone the Repository:

    git clone https://github.com/your-username/repo-name.git
    cd repo-name
  2. Install Dependencies:

    pip install -r requirements.txt
  3. Set Environment Variables: Create a .env file in the root directory and configure your environment variables, including database connection details and API tokens.

  4. Run FastAPI:

    uvicorn main:app --reload

    The API will be accessible at http://localhost:8000.

Setting Up PostgreSQL:

  1. Install PostgreSQL: Follow the instructions on the official PostgreSQL website to install PostgreSQL on your system.

  2. Create Database:

    createdb social_media_db
  3. Run Database Migrations:

    alembic upgrade head

    This will apply the necessary database migrations.

  4. Configure Database URL: Update the .env file with your PostgreSQL database URL:

    DATABASE_URL=postgresql://username:password@localhost/social_media_db
    

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages