Skip to content

Installation_guide

Aditya Chatterjee edited this page Mar 10, 2018 · 2 revisions

Installation guide to run Cosmos-Search locally

The average time to setup Cosmos-Search locally has been reported to be πŸš„ 2 minutes. Follow the following steps to get started instantly:

  1. Clone this wonderful repository in your local machine πŸ–₯️ :

    $ git clone https://github.com/OpenGenus/cosmos-search.git
    
  2. Go inside code 🏑 :

    $ cd cosmos-search
    
  3. Setup a virtual environment 🏘️ :

    $ virtualenv -m python3 env_name OR $ python3 -m venv env_name

  4. Activate the virtual environment πŸŒ€ :

    $ source env_name/bin/activate
    

    The virtual environment can be deactivated with the deactivate command.

  5. Install local dependencies πŸ› οΈ :

     pip install -r requirements.txt
    
  6. Copy the .env.example file to .env and supply values for the required variables using the following command πŸƒβ€β™‚οΈ :

      cp .env.example .env
    
  7. Collect static files using πŸ“š :

    $ python manage.py collectstatic
    
  8. Migrating files using πŸ“¨ :

    $ python manage.py migrate
    
  9. Run Cosmos-Search πŸš— :

    $ python manage.py runserver
    
  10. View this wonderful search engine built for you 😍 :

    localhost:8000
    

To run the web app in Debug mode set the DEBUG environment variable. In Linux, run the export DEBUG=True command in the terminal.

Any questions?

Get in touch with us at Slack or ask us at our Discourse forum.