Giter Site home page Giter Site logo

kamandprompt / sntc-calendar Goto Github PK

View Code? Open in Web Editor NEW
2.0 3.0 14.0 403 KB

Event Calendar for IIT Mandi's Gymkhana

Home Page: https://activities.iitmandi.co.in

Python 70.22% HTML 22.57% CSS 7.21%
hacktoberfest2021 hacktoberfest2021-accepted hacktoberfest

sntc-calendar's Introduction

GYMKHANA Calendar

Installing and running

Clone the repository

Add ALLOWED_HOSTS in mycalendar/settings.py for deployment

Install virtual environment

Install pip first

sudo apt-get install python3-pip

Then install virtualenv using pip3

pip3 install virtualenv 

Now create a virtual environment

virtualenv venv 

you can use any name insted of venv

Active your virtual environment:

source venv/bin/activate

Run the following commands in project directory.

You might need to delete db.sqlite3 to start afresh.

pip install -r requirements.txt
python manage.py makemigrations
python manage.py migrate --run-syncdb
python manage.py collectstatic
python manage.py createsuperuser
python manage.py runserver

Adding Google OAuth2.0 API Key's credentials in admin Social Applications.

  1. create a Google Cloud Console Project.

  2. Go to Credentials, Auth consent, add a new app.

  3. Create new OAuth Credentials and download the json.

  4. Go to http://127.0.0.1:8000/admin and sign in as superuser.

  5. Add a new Site.

  6. Add the Social Applications and the credentials and the site.

  7. Copy .env.sample to a new file .env and add above credentials here also.

  8. You are ready to run the App!

For running the web-app on the server as a background process, use nohup.

nohup python manage.py runserver &  

This will output a PID, which can be later used to kill the process.


Updates:

Note: http urls are no longer supported for non local domains

"python manage.py createsuperuser" should be run separately when in Docker to create the admin

In /admin page, setup "Social applications"

users directly sign in using Oauth, only clubs/secretaries can create events so add them to clubs separately from /admin page

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.