I have a monorepo in Github that has been built with Turborepo. I want to deploy it in Azure App Service the backend app, but I'm having trouble finding out how to install turbo on Azure.
When the Github action starts running, it fails when doing npm install with this error:
npm ERR! [turbo] Failed to find package "turbo-linux-64" on the file system
I tried adding this step before building the app inside yml file:
steps:
- name: Install Turbo CLI
run: npm install turbo --global
but I still get the same error.
I also tried to install an Extension in App Service configuration but I don't find the option.
If I install turbo using ssh console, it won't persist, so it will fail again.
Any idea how to do this?
I tried adding this step before building the app inside yml file:
Instead of Installing the turbo-linux-64
inside yml file, Install it directly in the Azure Linux App Service
.
Check the below steps:
Create an Azure Linux App Service
with RuntimeStack
as Node
.
npm ERR! [turbo] Failed to find package "turbo-linux-64" on the file system
Navigate to your App Service
=> Advanced Tools
=> Go
=> SSH
Run the below command to Install the turbo-linux-64
.
npm install turbo-linux-64
OR
Open the DebugConsole
directly with the below URL.
https://YourWebAppName.scm.azurewebsites.net/
turbo-linux-64
version by using the npm ls turbo-linux-64
command.npm install turbo --global
which you have tried in yml file
.turbo
without any issues. Check the Installed turbo version using turbo --version
.If I install turbo using ssh console, it won't persist, so it will fail again.
If you want to persist the Installed turbo, then we can add a Startup script in the App Service
=> Configuration
=> General Settings
section.
Add the npm install turbo-linux-64 --global
command in the startup script.
Whenever the Application gets started the startup script will run automatically and Install the specified Packages.
Save and restart the Application.
Now check whether the turbo is Install or not using the same command turbo --version
in SSH.
Now deploy your application as usual from the Deployment Center
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With