GithubHelp home page GithubHelp logo

Deployment broken about eb-fix-npm HOT 8 OPEN

mixmaxhq avatar mixmaxhq commented on May 31, 2024
Deployment broken

from eb-fix-npm.

Comments (8)

rkrasiuk avatar rkrasiuk commented on May 31, 2024 2

@xurei @wearhere any update on the issue? having same trouble here

from eb-fix-npm.

wearhere avatar wearhere commented on May 31, 2024

Hm, it looks like the Elastic Beanstalk staging directory (/tmp/deployment/application/) is unclean for some reason. What version of the EB Node.js platform do you use and what are the contents of /opt/elasticbeanstalk/hooks/appdeploy/pre/ on one of your EC2 instances? I wonder if in a newer version of the EB platform, EB installs the node modules earlier than 50npm.sh.

Also if you run this script on a fresh EC2 instance (by terminating one of the instances in your application), does it work then?

from eb-fix-npm.

xurei avatar xurei commented on May 31, 2024

Platform version : 4.3.0
Content of directory (without eb-fix-npm) :
01_configure_xray.sh 10clean.sh 20unzip.sh 30config_clean.sh 40install_node.sh 50npm.sh 60config_generate.sh

It works the first time, yes. But if I try to update an existing instance it does not.

from eb-fix-npm.

wearhere avatar wearhere commented on May 31, 2024

Ok, my next move to debug this would be to check if, when you get the "/tmp/deployment/application/node_modules exists" error, /tmp/deployment/application/node_modules is a regular folder or already somehow is the symlink to /var/node_modules as initialized here. It might be that EB reuses the staging directory somehow on platform 4.3.0, and so that line needs to check whether the symlink exists already or not.

By the way, this module probably needs to be updated in other ways for platform 4.3.0. For instance, if you're using Node 8.x, thus npm 5, it might be that you no longer need to downgrade to npm 2 for speed reasons.

A disclaimer that's at the top of the README but I should repeat here: Mixmax no longer uses this module in favor of eb-disable-npm.

from eb-fix-npm.

d1manson avatar d1manson commented on May 31, 2024

ended up in a lot of EB pain.

from eb-fix-npm.

rkrasiuk avatar rkrasiuk commented on May 31, 2024

for anyone struggling, removing cached modules and setting up aws codepipeline helped

from eb-fix-npm.

dblythy avatar dblythy commented on May 31, 2024

@rkrasiuk could you please explain how to do this?

from eb-fix-npm.

rkrasiuk avatar rkrasiuk commented on May 31, 2024

@dblythy well, i couldn't get direct deployment to work, so i set up aws codepipeline - webhook for github -> aws codebuild -> deployment to eb. hope that helps you!

from eb-fix-npm.

Related Issues (5)

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.