Skip to content

This repo contains the files regarding the backend of our project

Notifications You must be signed in to change notification settings

llr-opensoft-24/opensoft-backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

71 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Backend

Local Installation

  1. Clone and create, activate virtual environment
python3 -m venv venv
source venv/bin/activate
  1. Install the required libraries
pip3 install -r requirements.txt
  1. Add the required credentials and other variables to .env file following the .env.example template
touch .env
  1. Start the server as standalone for development purposes
python3 app.py
  1. Start the server for deployment purposes
gunicorn -b 0.0.0.0:8000 app:app
  1. Run the app as a service using systemd in Linux systems
sudo nano /etc/systemd/system/flixpedia.service

Add the following contents into the above mentioned file:

[Unit]
Description=Gunicorn instance for running FlixPedia
After=network.target
[Service]
User={USERNAME_HERE}
Group=www-data
WorkingDirectory={WORKING_DIRECTORY_HERE}
ExecStart={WORKING_DIRECTORY_HERE}/venv/bin/gunicorn -b localhost:8000 app:app
Restart=always
[Install]
WantedBy=multi-user.target

Enable the service

sudo systemctl daemon-reload
sudo systemctl start flixpedia.service
sudo systemctl enable flixpedia.service

About

This repo contains the files regarding the backend of our project

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages