A minimal clone of Freelancer.com Back-end
python3.10 -m venv venv
pip install -r requirements.txt
CREATE DATABASE <database_name>;
CREATE USER <username>;
GRANT ALL PRIVILEGES ON DATABASE <database_name> TO <username>;
ALTER USER user_name WITH PASSWORD '<password>';
SECRET_KEY='Your Secret Key generated by https://djecrety.ir'
DEBUG= 'Status of debug of the proejct'
ALLOWED_HOSTS= ''
DB_NAME= '<user_name>'
DB_USER= '<password>'
DB_PASSWORD= '<database_name>'
DB_HOST='localhost'
DB_PORT=5432
EMAIL_HOST_USER= '<your_email_host_user'
EMAIL_HOST_PASSWORD = '<your_email_host_password'
python manage.py migrate
if you see this error message:
django.db.utils.ProgrammingError: permission denied to create extension "citext"
HINT: Must be superuser to create this extension.
Just enter this command to your database shell:
ALTER ROLE freedjancer SUPERUSER;