🔧 chore(Makefile): simplify frontend target by combining install_frontend and run_frontend commands
🐛 fix(Makefile): handle error in install_frontend command and attempt to fix it by running install_frontendc 🔧 chore(Makefile): simplify backend target by combining install_backend and run_backend commands ✨ feat(Makefile): add support for login flag to control autologin feature in backend command
This commit is contained in:
parent
419822211f
commit
6f1306887a
1 changed files with 7 additions and 11 deletions
18
Makefile
18
Makefile
|
|
@ -53,12 +53,8 @@ setup_devcontainer:
|
||||||
poetry run langflow --path src/frontend/build
|
poetry run langflow --path src/frontend/build
|
||||||
|
|
||||||
frontend:
|
frontend:
|
||||||
@-make install_frontend
|
@-make install_frontend || (echo "An error occurred while installing frontend dependencies. Attempting to fix." && make install_frontendc)
|
||||||
@if [ $$? -ne 0 ]; then \
|
@make run_frontend
|
||||||
echo "An error occurred while installing frontend dependencies. Attempting to fix."; \
|
|
||||||
make install_frontendc; \
|
|
||||||
fi
|
|
||||||
make run_frontend
|
|
||||||
|
|
||||||
frontendc:
|
frontendc:
|
||||||
make install_frontendc
|
make install_frontendc
|
||||||
|
|
@ -69,12 +65,12 @@ install_backend:
|
||||||
|
|
||||||
backend:
|
backend:
|
||||||
make install_backend
|
make install_backend
|
||||||
ifeq ($(autologin),1)
|
ifeq ($(login),1)
|
||||||
@echo "Running backend with autologin";
|
|
||||||
LANGFLOW_AUTO_LOGIN=True poetry run langflow run --backend-only --port 7860 --host 0.0.0.0
|
|
||||||
else
|
|
||||||
@echo "Running backend without autologin";
|
@echo "Running backend without autologin";
|
||||||
poetry run langflow run --backend-only --port 7860 --host 0.0.0.0
|
poetry run langflow run --backend-only --port 7860 --host 0.0.0.0 --no-open-browser
|
||||||
|
else
|
||||||
|
@echo "Running backend with autologin";
|
||||||
|
LANGFLOW_AUTO_LOGIN=True poetry run langflow run --backend-only --port 7860 --host 0.0.0.0 --no-open-browser
|
||||||
endif
|
endif
|
||||||
|
|
||||||
build_and_run:
|
build_and_run:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue