简体   繁体   中英

How do I deploy an express node-js implementation on openshift using github source?

I have tried following the documentation and even deployed the sample app, but I keep running into the following build error:

Cloning "https://github.com/neelrr1/bordPublic " ...
    Commit: 676e5b2c72118cba4079d437232ad320beb85231 (alot of changes...)
    Author: Neel Raja <abdulbasit.ali.2000@gmail.com>
    Date:   Sat Sep 1 03:13:56 2018 +0000
Pulling image "docker-registry.default.svc:5000/openshift/nodejs@sha256:b605bc8d918f88602d038f0c23268343d3aee6445de0806ce4ff8e67c4d14c66" ...
---> Installing application source
---> Building your Node application from source
Current git config
url.https://github.com.insteadof=git@github.com: 
url.https://.insteadof=ssh:// 
url.https://github.com.insteadof=ssh://git@github.com 
core.repositoryformatversion=0
core.filemode=true
core.bare=false
core.logallrefupdates=true
remote.origin.url=https://github.com/neelrr1/bordPublic 
remote.origin.fetch=+refs/heads/master:refs/remotes/origin/master
branch.master.remote=origin
branch.master.merge=refs/heads/master
---> Installing dependencies
---> Using 'npm install -s --only=production'
error: build error: non-zero (13) exit code from docker-registry.default.svc:5000/openshift/nodejs@sha256:b605bc8d918f88602d038f0c23268343d3aee6445de0806ce4ff8e67c4d14c66

I am trying to use just github source to build my app, but I am open to trying other ideas that may work. Thanks!

The npm program is known to be a memory hog when installing packages. You are most likely running out of memory. Increase the amount of memory given to the build. See:

In short, to increase memory run:

oc patch bc/yourappname --patch '{"spec":{"resources":{"limits":{"memory":"1Gi"}}}}'

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM