How to set nodejs version in azure











up vote
0
down vote

favorite












I'm deploying angular 7 app to Azure using bitbucket, I'm using this script in package.json



"scripts": {
"ng": "ng",
"start-ng": "ng serve",
"build": "ng build --prod",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e",
"postinstall": "npm run build"
},
"engines": {
"node": "8.11.1"
},



and set Application directory to




sitewwwrootdistmyapp




but it failed, here is the log



Running deployment command



I've deployed angular 5 app to Azure in the same way previously and it works fine



Updates



I've set the default node and npm version in package.json and add them as default variable in Application setting
so the new errors is
log










share|improve this question









New contributor




Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















  • Hi Kenada, welcome to S.O!! How are you deploying your code to azure? Are you using some kind of functionality like heroku? What is the s.o of your box in azure?
    – JRichardsz
    2 days ago










  • Hi @JRichardsz well, I don't use heroku, I'm only execute this script in package.json , by defualt, there is default deployment command from kudu that is executed
    – Kenana Reda
    2 days ago










  • @JRichardsz I've updated the post, pls have alook
    – Kenana Reda
    2 days ago










  • I can see in your log, you use windows as server. My first advice is : Windows is not the best choice to work with nodejs. Linux box or a minimal linux docker container is the best choice to work with nodejs in production
    – JRichardsz
    2 days ago










  • According to your log, you need a dependency. Try this : npm install --save-dev @angular-devkit/build-angular
    – JRichardsz
    2 days ago















up vote
0
down vote

favorite












I'm deploying angular 7 app to Azure using bitbucket, I'm using this script in package.json



"scripts": {
"ng": "ng",
"start-ng": "ng serve",
"build": "ng build --prod",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e",
"postinstall": "npm run build"
},
"engines": {
"node": "8.11.1"
},



and set Application directory to




sitewwwrootdistmyapp




but it failed, here is the log



Running deployment command



I've deployed angular 5 app to Azure in the same way previously and it works fine



Updates



I've set the default node and npm version in package.json and add them as default variable in Application setting
so the new errors is
log










share|improve this question









New contributor




Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















  • Hi Kenada, welcome to S.O!! How are you deploying your code to azure? Are you using some kind of functionality like heroku? What is the s.o of your box in azure?
    – JRichardsz
    2 days ago










  • Hi @JRichardsz well, I don't use heroku, I'm only execute this script in package.json , by defualt, there is default deployment command from kudu that is executed
    – Kenana Reda
    2 days ago










  • @JRichardsz I've updated the post, pls have alook
    – Kenana Reda
    2 days ago










  • I can see in your log, you use windows as server. My first advice is : Windows is not the best choice to work with nodejs. Linux box or a minimal linux docker container is the best choice to work with nodejs in production
    – JRichardsz
    2 days ago










  • According to your log, you need a dependency. Try this : npm install --save-dev @angular-devkit/build-angular
    – JRichardsz
    2 days ago













up vote
0
down vote

favorite









up vote
0
down vote

favorite











I'm deploying angular 7 app to Azure using bitbucket, I'm using this script in package.json



"scripts": {
"ng": "ng",
"start-ng": "ng serve",
"build": "ng build --prod",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e",
"postinstall": "npm run build"
},
"engines": {
"node": "8.11.1"
},



and set Application directory to




sitewwwrootdistmyapp




but it failed, here is the log



Running deployment command



I've deployed angular 5 app to Azure in the same way previously and it works fine



Updates



I've set the default node and npm version in package.json and add them as default variable in Application setting
so the new errors is
log










share|improve this question









New contributor




Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











I'm deploying angular 7 app to Azure using bitbucket, I'm using this script in package.json



"scripts": {
"ng": "ng",
"start-ng": "ng serve",
"build": "ng build --prod",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e",
"postinstall": "npm run build"
},
"engines": {
"node": "8.11.1"
},



and set Application directory to




sitewwwrootdistmyapp




but it failed, here is the log



Running deployment command



I've deployed angular 5 app to Azure in the same way previously and it works fine



Updates



I've set the default node and npm version in package.json and add them as default variable in Application setting
so the new errors is
log







angular azure deployment devops angular7






share|improve this question









New contributor




Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited yesterday





















New contributor




Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked 2 days ago









Kenana Reda

86




86




New contributor




Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












  • Hi Kenada, welcome to S.O!! How are you deploying your code to azure? Are you using some kind of functionality like heroku? What is the s.o of your box in azure?
    – JRichardsz
    2 days ago










  • Hi @JRichardsz well, I don't use heroku, I'm only execute this script in package.json , by defualt, there is default deployment command from kudu that is executed
    – Kenana Reda
    2 days ago










  • @JRichardsz I've updated the post, pls have alook
    – Kenana Reda
    2 days ago










  • I can see in your log, you use windows as server. My first advice is : Windows is not the best choice to work with nodejs. Linux box or a minimal linux docker container is the best choice to work with nodejs in production
    – JRichardsz
    2 days ago










  • According to your log, you need a dependency. Try this : npm install --save-dev @angular-devkit/build-angular
    – JRichardsz
    2 days ago


















  • Hi Kenada, welcome to S.O!! How are you deploying your code to azure? Are you using some kind of functionality like heroku? What is the s.o of your box in azure?
    – JRichardsz
    2 days ago










  • Hi @JRichardsz well, I don't use heroku, I'm only execute this script in package.json , by defualt, there is default deployment command from kudu that is executed
    – Kenana Reda
    2 days ago










  • @JRichardsz I've updated the post, pls have alook
    – Kenana Reda
    2 days ago










  • I can see in your log, you use windows as server. My first advice is : Windows is not the best choice to work with nodejs. Linux box or a minimal linux docker container is the best choice to work with nodejs in production
    – JRichardsz
    2 days ago










  • According to your log, you need a dependency. Try this : npm install --save-dev @angular-devkit/build-angular
    – JRichardsz
    2 days ago
















Hi Kenada, welcome to S.O!! How are you deploying your code to azure? Are you using some kind of functionality like heroku? What is the s.o of your box in azure?
– JRichardsz
2 days ago




Hi Kenada, welcome to S.O!! How are you deploying your code to azure? Are you using some kind of functionality like heroku? What is the s.o of your box in azure?
– JRichardsz
2 days ago












Hi @JRichardsz well, I don't use heroku, I'm only execute this script in package.json , by defualt, there is default deployment command from kudu that is executed
– Kenana Reda
2 days ago




Hi @JRichardsz well, I don't use heroku, I'm only execute this script in package.json , by defualt, there is default deployment command from kudu that is executed
– Kenana Reda
2 days ago












@JRichardsz I've updated the post, pls have alook
– Kenana Reda
2 days ago




@JRichardsz I've updated the post, pls have alook
– Kenana Reda
2 days ago












I can see in your log, you use windows as server. My first advice is : Windows is not the best choice to work with nodejs. Linux box or a minimal linux docker container is the best choice to work with nodejs in production
– JRichardsz
2 days ago




I can see in your log, you use windows as server. My first advice is : Windows is not the best choice to work with nodejs. Linux box or a minimal linux docker container is the best choice to work with nodejs in production
– JRichardsz
2 days ago












According to your log, you need a dependency. Try this : npm install --save-dev @angular-devkit/build-angular
– JRichardsz
2 days ago




According to your log, you need a dependency. Try this : npm install --save-dev @angular-devkit/build-angular
– JRichardsz
2 days ago












2 Answers
2






active

oldest

votes

















up vote
0
down vote













You are running version v0.10.40 of Node.js, which is not supported by Angular CLI v6 and above.
The official Node.js version that is supported is 8.9 and greater.



Please visit https://nodejs.org/en/ to find the instructions on how to update Node.js






share|improve this answer





















  • Thanks for answering, I have specified node version in package.json and set "engines" to "8.11.1", I've updated the post
    – Kenana Reda
    2 days ago












  • so don't know Why this error is appear!, even I choose node version, and at the beginning in the log you van notice that the selected node version is 8.11.1
    – Kenana Reda
    2 days ago


















up vote
0
down vote



accepted










The answer was adding
WEBSITE_NODE_DEFAULT_VERSION in Application setting string, even adding



"engines": {
"node": "8.11.1"
},



in package.json have no effect, another solution is to add issnode.yml file and to project file
and add this command to it
nodeProcessCommandLine: "D:Program Files (x86)nodejs8.11.1node.exe"






share|improve this answer








New contributor




Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.


















    Your Answer






    StackExchange.ifUsing("editor", function () {
    StackExchange.using("externalEditor", function () {
    StackExchange.using("snippets", function () {
    StackExchange.snippets.init();
    });
    });
    }, "code-snippets");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "1"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });






    Kenana Reda is a new contributor. Be nice, and check out our Code of Conduct.










     

    draft saved


    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53373603%2fhow-to-set-nodejs-version-in-azure%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    0
    down vote













    You are running version v0.10.40 of Node.js, which is not supported by Angular CLI v6 and above.
    The official Node.js version that is supported is 8.9 and greater.



    Please visit https://nodejs.org/en/ to find the instructions on how to update Node.js






    share|improve this answer





















    • Thanks for answering, I have specified node version in package.json and set "engines" to "8.11.1", I've updated the post
      – Kenana Reda
      2 days ago












    • so don't know Why this error is appear!, even I choose node version, and at the beginning in the log you van notice that the selected node version is 8.11.1
      – Kenana Reda
      2 days ago















    up vote
    0
    down vote













    You are running version v0.10.40 of Node.js, which is not supported by Angular CLI v6 and above.
    The official Node.js version that is supported is 8.9 and greater.



    Please visit https://nodejs.org/en/ to find the instructions on how to update Node.js






    share|improve this answer





















    • Thanks for answering, I have specified node version in package.json and set "engines" to "8.11.1", I've updated the post
      – Kenana Reda
      2 days ago












    • so don't know Why this error is appear!, even I choose node version, and at the beginning in the log you van notice that the selected node version is 8.11.1
      – Kenana Reda
      2 days ago













    up vote
    0
    down vote










    up vote
    0
    down vote









    You are running version v0.10.40 of Node.js, which is not supported by Angular CLI v6 and above.
    The official Node.js version that is supported is 8.9 and greater.



    Please visit https://nodejs.org/en/ to find the instructions on how to update Node.js






    share|improve this answer












    You are running version v0.10.40 of Node.js, which is not supported by Angular CLI v6 and above.
    The official Node.js version that is supported is 8.9 and greater.



    Please visit https://nodejs.org/en/ to find the instructions on how to update Node.js







    share|improve this answer












    share|improve this answer



    share|improve this answer










    answered 2 days ago









    Mukesh Kumar

    330112




    330112












    • Thanks for answering, I have specified node version in package.json and set "engines" to "8.11.1", I've updated the post
      – Kenana Reda
      2 days ago












    • so don't know Why this error is appear!, even I choose node version, and at the beginning in the log you van notice that the selected node version is 8.11.1
      – Kenana Reda
      2 days ago


















    • Thanks for answering, I have specified node version in package.json and set "engines" to "8.11.1", I've updated the post
      – Kenana Reda
      2 days ago












    • so don't know Why this error is appear!, even I choose node version, and at the beginning in the log you van notice that the selected node version is 8.11.1
      – Kenana Reda
      2 days ago
















    Thanks for answering, I have specified node version in package.json and set "engines" to "8.11.1", I've updated the post
    – Kenana Reda
    2 days ago






    Thanks for answering, I have specified node version in package.json and set "engines" to "8.11.1", I've updated the post
    – Kenana Reda
    2 days ago














    so don't know Why this error is appear!, even I choose node version, and at the beginning in the log you van notice that the selected node version is 8.11.1
    – Kenana Reda
    2 days ago




    so don't know Why this error is appear!, even I choose node version, and at the beginning in the log you van notice that the selected node version is 8.11.1
    – Kenana Reda
    2 days ago












    up vote
    0
    down vote



    accepted










    The answer was adding
    WEBSITE_NODE_DEFAULT_VERSION in Application setting string, even adding



    "engines": {
    "node": "8.11.1"
    },



    in package.json have no effect, another solution is to add issnode.yml file and to project file
    and add this command to it
    nodeProcessCommandLine: "D:Program Files (x86)nodejs8.11.1node.exe"






    share|improve this answer








    New contributor




    Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.






















      up vote
      0
      down vote



      accepted










      The answer was adding
      WEBSITE_NODE_DEFAULT_VERSION in Application setting string, even adding



      "engines": {
      "node": "8.11.1"
      },



      in package.json have no effect, another solution is to add issnode.yml file and to project file
      and add this command to it
      nodeProcessCommandLine: "D:Program Files (x86)nodejs8.11.1node.exe"






      share|improve this answer








      New contributor




      Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.




















        up vote
        0
        down vote



        accepted







        up vote
        0
        down vote



        accepted






        The answer was adding
        WEBSITE_NODE_DEFAULT_VERSION in Application setting string, even adding



        "engines": {
        "node": "8.11.1"
        },



        in package.json have no effect, another solution is to add issnode.yml file and to project file
        and add this command to it
        nodeProcessCommandLine: "D:Program Files (x86)nodejs8.11.1node.exe"






        share|improve this answer








        New contributor




        Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.









        The answer was adding
        WEBSITE_NODE_DEFAULT_VERSION in Application setting string, even adding



        "engines": {
        "node": "8.11.1"
        },



        in package.json have no effect, another solution is to add issnode.yml file and to project file
        and add this command to it
        nodeProcessCommandLine: "D:Program Files (x86)nodejs8.11.1node.exe"







        share|improve this answer








        New contributor




        Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.









        share|improve this answer



        share|improve this answer






        New contributor




        Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.









        answered yesterday









        Kenana Reda

        86




        86




        New contributor




        Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.





        New contributor





        Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.






        Kenana Reda is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.






















            Kenana Reda is a new contributor. Be nice, and check out our Code of Conduct.










             

            draft saved


            draft discarded


















            Kenana Reda is a new contributor. Be nice, and check out our Code of Conduct.













            Kenana Reda is a new contributor. Be nice, and check out our Code of Conduct.












            Kenana Reda is a new contributor. Be nice, and check out our Code of Conduct.















             


            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53373603%2fhow-to-set-nodejs-version-in-azure%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Can a sorcerer learn a 5th-level spell early by creating spell slots using the Font of Magic feature?

            Does disintegrating a polymorphed enemy still kill it after the 2018 errata?

            A Topological Invariant for $pi_3(U(n))$