Skip to content
This repository has been archived by the owner on Feb 16, 2023. It is now read-only.

BACKEND_URL & URL validation #51

Open
taiqn opened this issue Jul 9, 2022 · 3 comments
Open

BACKEND_URL & URL validation #51

taiqn opened this issue Jul 9, 2022 · 3 comments

Comments

@taiqn
Copy link

taiqn commented Jul 9, 2022

Hi, I need help.

I already set REACT_APP_BACKEND_URL= in client .env but in the logs show backend_url not found.

And could you please add a validator to check in put URL as valid or not.

Thanks

@Just-Moh-it
Copy link
Owner

Hey, if you're following the instructions in the docs, you need to comment that line out, since the UI will automatically request from the URL it's currently on (because the backend and the frontend are run on the same server in production build). Just add a # to the beginning of that line, since it doesn't require changes (that's why it's optional).

I do agree it needs a better comment message.

@taiqn
Copy link
Author

taiqn commented Jul 9, 2022

Tried to deploy to Heroku and see as it works, got error and this log

2022-07-09T10:36:44.822519+00:00 heroku[worker.1]: Starting process with command nginx -g daemon\ off\;
2022-07-09T10:36:45.917800+00:00 heroku[worker.1]: State changed from starting to up
2022-07-09T10:36:46.310869+00:00 heroku[worker.1]: Process exited with status 127
2022-07-09T10:36:46.417508+00:00 heroku[worker.1]: State changed from up to crashed
2022-07-09T10:36:46.421808+00:00 heroku[worker.1]: State changed from crashed to starting
2022-07-09T10:36:46.127719+00:00 app[worker.1]: BACKEND_URL not set, defaulting to
2022-07-09T10:36:46.127755+00:00 app[worker.1]: Setting up NGINX config
2022-07-09T10:36:46.129762+00:00 app[worker.1]: Resolving to an IP address...
2022-07-09T10:36:46.133379+00:00 app[worker.1]: Resolved to 127.0.0.1
2022-07-09T10:36:46.136106+00:00 app[worker.1]: sed: -e expression #1, char 0: no previous regular expression
2022-07-09T10:36:46.136306+00:00 app[worker.1]: Substituted with 127.0.0.1 in
2022-07-09T10:36:46.139762+00:00 app[worker.1]: Starting NGINX...
2022-07-09T10:36:46.139806+00:00 app[worker.1]: /entrypoint.sh: 33: exec: BACKEND_URL=http://server:4000: not found
2022-07-09T10:37:11.341258+00:00 heroku[worker.1]: Starting process with command nginx -g daemon\ off\;
2022-07-09T10:37:11.974137+00:00 heroku[worker.1]: State changed from starting to up
2022-07-09T10:37:12.143128+00:00 app[worker.1]: BACKEND_URL not set, defaulting to
2022-07-09T10:37:12.143165+00:00 app[worker.1]: Setting up NGINX config
2022-07-09T10:37:12.146111+00:00 app[worker.1]: Resolving to an IP address...
2022-07-09T10:37:12.151736+00:00 app[worker.1]: Resolved to 127.0.0.1
2022-07-09T10:37:12.154966+00:00 app[worker.1]: sed: -e expression #1, char 0: no previous regular expression
2022-07-09T10:37:12.155171+00:00 app[worker.1]: Substituted with 127.0.0.1 in
2022-07-09T10:37:12.161363+00:00 app[worker.1]: Starting NGINX...
2022-07-09T10:37:12.161414+00:00 app[worker.1]: /entrypoint.sh: 33: exec: BACKEND_URL=http://server:4000: not found
2022-07-09T10:37:12.274108+00:00 heroku[worker.1]: Process exited with status 127
2022-07-09T10:37:13.714453+00:00 heroku[worker.1]: State changed from up to crashed

Hope you can help, thanks

@Just-Moh-it
Copy link
Owner

Docker install is currently not stable: https://docs.pckd.me/docs/install-from-docker-compose

I'd recommend installing from code

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

No branches or pull requests

2 participants