datajoint / pharus

Pharus is a generic REST API server backend for DataJoint pipelines built on top of flask, datajoint, and pyjwt.
https://datajoint.com/docs/core/pharus
MIT License
3 stars 15 forks source link

Setting Up Issue #74

Closed ChihweiLHBird closed 3 years ago

ChihweiLHBird commented 3 years ago

Hi, I am Zhiwei, and I would like to contribute to this project. I have some experience in React and Flask framework.

I am trying to run the backend and connect it to the frontend. But the docker file local-docker-compose.yaml was disappeared in today's master branch. I tried the docker-compose-test.yaml with the given command PHARUS_VERSION=$(cat pharus/version.py | tail -1 | awk -F\' '{print $2}') HOST_UID=$(id -u) docker-compose -f docker-compose-test.yaml up --exit-code-from pharus and got:

WARNING: using --exit-code-from implies --abort-on-container-exit
WARNING: Found orphan containers (pharus_dj-gui-api_1) for this project. If you removed or renamed this service in your compose file, you can run this command with the --remove-orphans flag to clean it up.
Building pharus
Step 1/11 : ARG PY_VER
Step 2/11 : ARG DISTRO
Step 3/11 : ARG IMAGE
Step 4/11 : FROM datajoint/${IMAGE}:py${PY_VER}-${DISTRO}
ERROR: Service 'pharus' failed to build : invalid reference format

I tried to run it with Python and run the frontend with docker, and I got the error in the frontend:

Proxy error: Could not proxy request /api/login from localhost:3000 to http://dj-gui-api:5000 (EAI_AGAIN).

I am wondering if there is a simple to launch the frontend and the backend and connect them? Thank you!

guzman-raphael commented 3 years ago

Welcome @ChihweiLHBird! Picking up the conversation here from my last message in DataJoint Slack.

You are likely experiencing mixed-state issues since we are currently in the process of making our first ALPHA release (delayed on account of the city-wide power outage due to winter storm). Let me issue quickly a new update for pharus with more notes to help. We should have a release later today for datajoint-labbook.