GithubHelp home page GithubHelp logo

Comments (14)

catamphetamine avatar catamphetamine commented on May 24, 2024

Does it work locally?
Your host: 'http://XXXXX.elasticbeanstalk.com/', setting is wrong.
It says host, not url.

from react-pages.

weatherfordmat avatar weatherfordmat commented on May 24, 2024

Yes, it works in development and production modes locally. I had tried 127.0.0.1, localhost, etc.

from react-pages.

catamphetamine avatar catamphetamine commented on May 24, 2024

See my comment above.
Your host: 'http://XXXXX.elasticbeanstalk.com/' setting is wrong.

from react-pages.

weatherfordmat avatar weatherfordmat commented on May 24, 2024

So I changed this to localhost and also tried 127.0.0.1 with no luck.

from react-pages.

catamphetamine avatar catamphetamine commented on May 24, 2024

No, do it like host: 'XXXXX.elasticbeanstalk.com'

from react-pages.

weatherfordmat avatar weatherfordmat commented on May 24, 2024

Thanks for the catch.

It is still not correctly working though. It is giving me the following response:

npm ERR! Linux 4.9.32-15.41.amzn1.x86_64
npm ERR! argv "/opt/elasticbeanstalk/node-install/node-v7.6.0-linux-x64/bin/node" "/opt/elasticbeanstalk/node-install/node-v7.6.0-linux-x64/lib/node_modules/npm/bin/npm-cli.js" "run" "production:client:build"
npm ERR! node v7.6.0
npm ERR! npm v4.1.2
npm ERR! code ELIFECYCLE

from react-pages.

catamphetamine avatar catamphetamine commented on May 24, 2024

The error dump has no details

from react-pages.

weatherfordmat avatar weatherfordmat commented on May 24, 2024

Deploy.txt no longer available.

from react-pages.

weatherfordmat avatar weatherfordmat commented on May 24, 2024

I thought it had something to do with the version matching between node/npm and other packages, but it doesn't seem to be a result.

from react-pages.

adailey14 avatar adailey14 commented on May 24, 2024

Hey @weatherfordmat, I use this repo on elastic beanstalk, but it takes some work.

The main problem is that Elastic Beanstalk only gives you one port to work with (this is similar to other services like Heroku) but this project uses multiple ports to create a separation between the outer proxying layer, the data api, and the page rendering service.

So to get it to work with one port, you have to use koa-mount instead of proxying from the web service. It can be tricky to get this to work.

from react-pages.

weatherfordmat avatar weatherfordmat commented on May 24, 2024

Thanks adailey14! The solution seems to be a combination of (1) serving assets via koa-mount, (2) setting render: false in the application.js. file. I'm not sure if setting render to false is enough to serve the files without throwing the page rendering error. Is there anything else that comes to the top of your head that would make this work?

from react-pages.

catamphetamine avatar catamphetamine commented on May 24, 2024

@weatherfordmat You seem to not understand what's happening at all. The logs you provided are just a mishmash of everything you could think of and reach. My opinion is that you're taking the tasks you're not ready for at your current level of understanding things.

And also blindly posting your logs on the internets can share some secrets. Like don't be surprised if your AWS account runs low on budget the other day because of a bitcoin mining malware. I won't tell you the exact place but somewhere in this issue there are some secrets which I could use if I wanted to rule your servers like my own.

Now, for the "single port" thing. I updated the README.
The "Server side" section illustrates how to run everything on a single port.
https://github.com/halt-hammerzeit/react-isomorphic-render#server-side
https://github.com/halt-hammerzeit/react-isomorphic-render#serving-assets-and-api
There are 3 approaches described

from react-pages.

catamphetamine avatar catamphetamine commented on May 24, 2024

@adailey14 FYI: I made some tweaks to the library today.
The former application server-side setting was renamed to proxy (I guess you didn't use it anyway) and http utility method calls now only accept relative URLs (I guess that's how everyone uses it, but in case you had some absolute URLs there you've been notified).

from react-pages.

weatherfordmat avatar weatherfordmat commented on May 24, 2024

Thanks for guidance. I removed the txt file.

from react-pages.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.