By lilLobster
I am trying to install a fresh version of Laravel on DO’s App Platform.
However, the build is failing.
I am new to laravel, but why is there a dependency on node here?
dotest | 09:27:27 => Building app
dotest | 09:27:27
dotest | 09:27:27 ---> Node.js Buildpack
dotest | 09:27:27 ---> Installing toolbox
dotest | 09:27:27 ---> - jq
dotest | 09:27:29 ---> - yj
dotest | 09:27:31 ---> Getting Node version
dotest | 09:27:31 ---> Resolving Node version
dotest | 09:27:36 ---> Downloading and extracting Node v12.21.0
dotest | 09:27:54 ---> Parsing package.json
dotest | 09:27:56 ---> No file to start server
dotest | 09:27:56 ---> either use 'docker run' to start container or add index.js or server.js
dotest | 09:27:56 Installing node_modules using npm (from package-lock.json)
dotest | 09:27:59 npm ERR! cipm can only install packages with an existing package-lock.json or npm-shrinkwrap.json with lockfileVersion >= 1. Run an install with npm@5 or later to generate it, then try again.
dotest | 09:27:59
dotest | 09:27:59 npm ERR! A complete log of this run can be found in:
dotest | 09:27:59 npm ERR! /home/apps/.npm/_logs/2021-03-21T03_57_59_068Z-debug.log
dotest | 09:27:59 unable to invoke layer creator
dotest | 09:27:59 installing node_modules: exit status 1
dotest | 09:27:59 ERROR: failed to build: exit status 1
dotest | 09:27:59 ! Build failed (145)
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi,
From the output it looks like you need to push the package-lock.json file along with your project to git, otherwise will not be installed.
Have a look if it is not in .gitignore file, and try to remove from .gitignore and add to git, then push, if it is not there try to build your front-end locally first.
If still not working check your version of npm you might need to update it first.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.