By tobiasUrchin
I’m trying to deploy a Node.js app to App Platform (great product by the way) using the current version of yarn. I bootstrapped the repository using yarn set version berry.
The deployment installs yarn version 1.22.10 (which should be fine, since the yarnrc.yml points to the correct yarn binary). When it comes to installing the dependencies, the deployment uses a flag that is no longer supported: --network-timeout.
Below is the relevant section of the build log:
app | 01:15:04 => Building app
app | 01:15:04
app | 01:15:04 ---> Node.js Buildpack
app | 01:15:04 ---> Installing toolbox
app | 01:15:04 ---> - jq
app | 01:15:05 ---> - yj
app | 01:15:05 ---> Getting Node version
app | 01:15:05 ---> Resolving Node version
app | 01:15:07 ---> Downloading and extracting Node v12.21.0
app | 01:15:21 ---> Parsing package.json
app | 01:15:23 ---> Installing yarn@1.22.10
app | 01:15:28 ---> No file to start server
app | 01:15:28 ---> either use 'docker run' to start container or add index.js or server.js
app | 01:15:28 Installing node_modules using yarn (from yarn.lock)
app | 01:15:29 Unknown Syntax Error: Unsupported option name ("--network-timeout").
app | 01:15:29
app | 01:15:29 $ yarn install [--json] [--immutable] [--immutable-cache] [--check-cache] [--inline-builds] [--skip-builds]
app | 01:15:29 unable to invoke layer creator
app | 01:15:29 installing node_modules: exit status 1
app | 01:15:29 ERROR: failed to build: exit status 1
app | 01:15:29 ! Build failed (145)
Is it planned to support the current version of yarn on the App Platform?
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!
This comment has been deleted
Hi there,
Just came across this question and decided to post an update to anytone who comes across this in the future.
A new buildpack has been released recently with Ubuntu 22 which should contain all the LTS versions.
You can follow the steps here on how to upgrade or downgrade your buildpacks here:
https://docs.digitalocean.com/products/app-platform/how-to/change-stack/
Best,
Bobby
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.