Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document Development Pathway #47

Open
1 of 2 tasks
Tracked by #44
tyliec opened this issue Nov 24, 2023 · 7 comments
Open
1 of 2 tasks
Tracked by #44

Document Development Pathway #47

tyliec opened this issue Nov 24, 2023 · 7 comments
Assignees
Labels

Comments

@tyliec
Copy link
Member

tyliec commented Nov 24, 2023

Objective

The primary objective of this task is to outline the development pathway for contributors to UIPA.org. This document will serve as a guide, providing clear steps, best practices, and essential information to facilitate a smooth and efficient development process.

source froide-env/bin/activate # to activate the python virtualenv
python3 manage.py runserver
docker-compose up
vite dev

Tasks

  • Mac Developer Setup
  • Windows Developer Setup

Related Items

Parent Epic: #44

@tyliec
Copy link
Member Author

tyliec commented Jan 25, 2024

There are three main things that people have to stand up in order to start developing UIPA. These things are:

  1. The Databases (Elasticsearch & Postgres)
  2. The Backend (Django development server)
  3. The Frontend (vite)

At the end of setting up your development environment, you should have three terminal windows running each of these separately.

The Databases

Prerequisites

Instructions

The databases can be stood up together with one command using the provided docker-compose.yml

After running docker-compose up successfully, the output in your terminal should look something like:

Image

The Backend

Prerequisites

Instructions

To run the Django development server, we need to run the following commands:

# Installing dev-dependencies
pip install -r requirements-test.txt 

# To initialise the database:
python manage.py migrate --skip-checks

# Create a superuser
python manage.py createsuperuser

# Create and populate search index
python manage.py search_index --create
python manage.py search_index --populate

# Run the Django development server
python manage.py runserver

After running these, you should see something like this in your terminal:

Image

The Frontend

Prerequisites

Instructions

# Install the dependencies
yarn install

# Run the front-end server (vite)
yarn dev

After performing these steps, the application should be available at http://127.0.0.1:8000/ and look like:

Image

@tyliec
Copy link
Member Author

tyliec commented Jan 25, 2024

Created a PR adding this documentation to the README

@tyliec
Copy link
Member Author

tyliec commented Jan 30, 2024

Even though #63 has been merged, gonna work with @avenmia to have a Windows version of the dev instructions since #63 focuses on Mac development.

@tyliec
Copy link
Member Author

tyliec commented Feb 1, 2024

@all-contributors please add @avenmia for windows uipa dev instructions!

Copy link

@tyliec

I couldn't determine any contributions to add, did you specify any contributions?
Please make sure to use valid contribution names.

@tyliec
Copy link
Member Author

tyliec commented Feb 1, 2024

@all-contributors please add @avenmia for doc

Copy link

@tyliec

I've put up a pull request to add @avenmia! 🎉

@tyliec tyliec moved this to In Progress in UIPA.org Development Board Feb 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: In Progress
Development

No branches or pull requests

2 participants