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

[Bug] Error on Startup.cs (Linux) #11

Open
afiqahas92 opened this issue Mar 22, 2023 · 9 comments
Open

[Bug] Error on Startup.cs (Linux) #11

afiqahas92 opened this issue Mar 22, 2023 · 9 comments

Comments

@afiqahas92
Copy link

Screenshot 2023-03-22 111244

It got this error when I try to run the .dll. this at the last step

@afiqahas92 afiqahas92 changed the title [BUG] Error on Startup.cs (Linux) Mar 22, 2023
@afiqahas92 afiqahas92 changed the title Error on Startup.cs (Linux) [Bug] Error on Startup.cs (Linux) Mar 29, 2023
@leucoon
Copy link
Contributor

leucoon commented Mar 31, 2023

Replace the last command with the following
cd /ModernWMS/backen/ && dotnet ModernWMS.dll --urls http://0.0.0.0:20011

@afiqahas92
Copy link
Author

thanks for the reply. yes noticed that, and changed. But seems like the backend still not running even though I've open that particular port. website still can't use
Untitled

@leucoon
Copy link
Contributor

leucoon commented Mar 31, 2023

modify file .env.production and rebuild frontend with the following
cd /tmp/ModernWMS-master/frontend/
sed -i 's#http://127.0.0.1#http://IP address#g' ./.env.production
yarn && yarn build && cp -rf /tmp/ModernWMS-master/frontend/dist/* /etc/nginx/html/

@afiqahas92
Copy link
Author

afiqahas92 commented Mar 31, 2023

login
Screenshot 2023-04-04 175507
Screenshot 2023-04-05 145504

I've followed all the steps. Now the backend running when I checked http://ipaddress:20011 and try out the api. seems like database already connected correctly. But the frontend still requested from 127.0.0.1

@leucoon
Copy link
Contributor

leucoon commented Apr 10, 2023

Through the screenshot of the file [.env.production] provided by you, you have modified it correctly. Please check whether the compiled front end is accurately overwritten to the nginx directory "/etc/nginx/html/" .
if not, please retry the following
cd /tmp/ModernWMS-master/frontend/
yarn && yarn build
cp -rf /tmp/ModernWMS-master/frontend/dist/* /etc/nginx/html/

@afiqahas92
Copy link
Author

Through the screenshot of the file [.env.production] provided by you, you have modified it correctly. Please check whether the compiled front end is accurately overwritten to the nginx directory "/etc/nginx/html/" . if not, please retry the following cd /tmp/ModernWMS-master/frontend/ yarn && yarn build cp -rf /tmp/ModernWMS-master/frontend/dist/* /etc/nginx/html/

Actually I've done it all for few times already. Whenever I built new frontend, I'll check on "/etc/nginx/html/" folder. They're copied and updated whenever I executed the commands. That's why I'm not sure what else I'm missing that the ip address not changing.

@leucoon
Copy link
Contributor

leucoon commented Apr 11, 2023

Have you cleared the browser's cache after recompiling and overwritten to the nginx directory ?

@afiqahas92
Copy link
Author

afiqahas92 commented Apr 11, 2023

yes, cleared cache every time I rebuild. I even redo everything back for frontend in case I miss any step. But still request from http:127.0.0.1
1
2

@leucoon
Copy link
Contributor

leucoon commented Apr 11, 2023

It is recommended that you find a new server and reinstall it.

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

No branches or pull requests

2 participants