GithubHelp home page GithubHelp logo

chrismychen / kudu-yarn Goto Github PK

View Code? Open in Web Editor NEW

This project forked from stefangordon/kudu-yarn

0.0 1.0 0.0 6 KB

An example of using the Yarn package manager with Azure websites / Kudu.

License: MIT License

Batchfile 91.19% JavaScript 8.81%

kudu-yarn's Introduction

kudu-yarn

A sample demonstrating how to use the Yarn package manager with Azure websites / Kudu.

To use Yarn in your Azure App Services NodeJS application

Simply copy the deploy.cmd and .deployment files from this repository to yours. Kudu will use this deployment script instead of the built-in default.

How it works

The deploy.cmd in this repository is the default NodeJS installation script used by Kudu to install applications in Azure App Services, with a small modification to install Yarn and call yarn install instead of npm install

To run this sample

If you'd prefer to test using this sample instead of your own application, simply clone the repository and yarn install then yarn start to run.

To modify your existing deployment script

Find your existing call to npm install and replace it with yarn install. Prior to that step, leverage the built in npm to verify yarn is installed globally with npm install yarn -g. This might look like this in a default Kudu node deployment script.

:: 3. Install Yarn
echo Verifying Yarn Install.
call :ExecuteCmd !NPM_CMD! install yarn -g

:: 4. Install Yarn packages
echo Installing Yarn Packages.
IF EXIST "%DEPLOYMENT_TARGET%\package.json" (
  pushd "%DEPLOYMENT_TARGET%"
  call :ExecuteCmd yarn install --production
  IF !ERRORLEVEL! NEQ 0 goto error
  popd
)

kudu-yarn's People

Contributors

stefangordon avatar

Watchers

 avatar

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.