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

Invalid host header #11

Closed
ethcar opened this issue Mar 28, 2020 · 4 comments
Closed

Invalid host header #11

ethcar opened this issue Mar 28, 2020 · 4 comments

Comments

@ethcar
Copy link

ethcar commented Mar 28, 2020

Able to run the Application on the loaclhost and works fine.
Deployed on Digital ocean with apache configuration tested other apps work fine with Domain name and HTTPS.

Running this project results in error " Invalid host header "

tried all possible resolutions, updated the server hostname to match the same site(project)

Can tell me how I can fix this last issue of invalid host headers

@OssamaRafique
Copy link
Owner

Can you please share the screenshot? Also, I've updated the server.js file please check that too.

@ethcar
Copy link
Author

ethcar commented Mar 28, 2020

image

image

Compile is successful, Updated the server.js file as pointed out, still the same issue.

Also referred to : angular/angular-cli#6349

Where have you hosted your site, I am running on Digital Ocean?

@OssamaRafique
Copy link
Owner

Why you're starting it like that?
Please build and deploy static files.

Run this command
ng build --prod
Upload the files in your dist folder to the server.

@OssamaRafique
Copy link
Owner

If you still have issue, Please reopen this issue.
Thanks.

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