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

Hot reloadable dev setup through make rundev #497

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

ziakhan04
Copy link
Collaborator

@ziakhan04 ziakhan04 commented Mar 11, 2025

Reviewer: @lickem22
Estimate: 10 minutes


Ticket

Fixes: JIRA_TICKET_LINK

Description

Added the ability to run make rundev which will run the back end and front-end in hot reload mode, ie, changes made to the app will be reflected instantly.

Goal

Make dev faster and easier.

Changes

  • Added docker-compose-dev.yml (similar to .dev but did not want to delete that assuming some people prefer it)
  • Added make commands - rundev, stopdev, restartdev
  • Added Dockerfile.dev versions for admin and backend

Future Tasks (optional)

  • Delete docker-compose.dev.yml if people don't mind
  • Update the ReadMe if this is how we want to tell people to set up their dev environment
  • Can also add a speech module dev command for hot reloadable speech module dev setup

How has this been tested?

  • Ran make rundev/stopdev/restartdev
  • Changed stuff in the backend and saw that it reflected instantly (5 seconds)
  • Changed stuff in the front-end and saw that it got reflected instantly (1 second)

To-do before merge (optional)

  • Test yourself by running make rundev and modifying stuff and seeing it change instantly

Checklist

Fill with x for completed.

  • My code follows the style guidelines of this project
  • I have reviewed my own code to ensure good quality
  • I have tested the functionality of my code to ensure it works as intended
  • I have resolved merge conflicts

(Delete any items below that are not relevant)

  • I have updated the README file
  • I have updated affected documentation
  • I have added a blogpost in Latest Updates

Copy link
Contributor

@lickem22 lickem22 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @ziakhan04 ,
Made a few minor comments. But approved

@@ -139,3 +139,13 @@ setup-embeddings: guard-HUGGINGFACE_MODEL guard-HUGGINGFACE_EMBEDDINGS_API_KEY
teardown-embeddings:
@docker stop huggingface-embeddings
@docker rm huggingface-embeddings

rundev:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should rename to run-docker-compose and stop-docker-compose

COPY . .

# Make startup script executable
RUN chmod +x startup.sh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not useful anymore right?

@@ -4,8 +4,6 @@
from typing import AsyncIterator, Callable

import sentry_sdk
import sklearn # noqa
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why removing this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants