cannot touch '/usr/local/bin/goss': Permission denied

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












I have already used



 curl -fsSL


on Ubuntu 16.04,without any problems.
If I go for



sudo curl -fsSL https://goss.rocks/install | sh


then I have



touch: cannot touch '/usr/local/bin/goss': Permission denied
ERROR: Cannot write to /usr/local/bin set GOSS_DST elsewhere or use sudo


Is this somehow related to Goss tool or not?







share|improve this question












migrated from stackoverflow.com Apr 15 at 13:12


This question came from our site for professional and enthusiast programmers.


















    up vote
    0
    down vote

    favorite












    I have already used



     curl -fsSL


    on Ubuntu 16.04,without any problems.
    If I go for



    sudo curl -fsSL https://goss.rocks/install | sh


    then I have



    touch: cannot touch '/usr/local/bin/goss': Permission denied
    ERROR: Cannot write to /usr/local/bin set GOSS_DST elsewhere or use sudo


    Is this somehow related to Goss tool or not?







    share|improve this question












    migrated from stackoverflow.com Apr 15 at 13:12


    This question came from our site for professional and enthusiast programmers.
















      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I have already used



       curl -fsSL


      on Ubuntu 16.04,without any problems.
      If I go for



      sudo curl -fsSL https://goss.rocks/install | sh


      then I have



      touch: cannot touch '/usr/local/bin/goss': Permission denied
      ERROR: Cannot write to /usr/local/bin set GOSS_DST elsewhere or use sudo


      Is this somehow related to Goss tool or not?







      share|improve this question












      I have already used



       curl -fsSL


      on Ubuntu 16.04,without any problems.
      If I go for



      sudo curl -fsSL https://goss.rocks/install | sh


      then I have



      touch: cannot touch '/usr/local/bin/goss': Permission denied
      ERROR: Cannot write to /usr/local/bin set GOSS_DST elsewhere or use sudo


      Is this somehow related to Goss tool or not?









      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 23 at 10:32









      MikiBelavista

      317515




      317515




      migrated from stackoverflow.com Apr 15 at 13:12


      This question came from our site for professional and enthusiast programmers.






      migrated from stackoverflow.com Apr 15 at 13:12


      This question came from our site for professional and enthusiast programmers.






















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          2
          down vote



          accepted










          I don't see the relation to programming (it certainly would fit better on SuperUser or Unix/Linux), but the reason that you are denied the permission to do what you do is related to the user IDs your pipe components are executed under.



          With



          sudo a | b


          you are starting two processes, the first of them piping its output to the second one. The first one (sudo) executes another one (a) and feeds its output to b, which is executed with you UID.



          If you change the way things are done (fetching install script as "you" and executing it as root), it will probably work. But you put a lot of trust in whoever puts this file onto that web site.






          share|improve this answer




















          • Thanks,you think that I should not install it as root before doublecheck?
            – MikiBelavista
            Mar 23 at 10:45










          • @MikiBelavista Yes. Doing something as root always needs extra attention.
            – glglgl
            Mar 23 at 11:21










          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "106"
          ;
          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: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );








           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f437894%2fcannot-touch-usr-local-bin-goss-permission-denied%23new-answer', 'question_page');

          );

          Post as a guest






























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          2
          down vote



          accepted










          I don't see the relation to programming (it certainly would fit better on SuperUser or Unix/Linux), but the reason that you are denied the permission to do what you do is related to the user IDs your pipe components are executed under.



          With



          sudo a | b


          you are starting two processes, the first of them piping its output to the second one. The first one (sudo) executes another one (a) and feeds its output to b, which is executed with you UID.



          If you change the way things are done (fetching install script as "you" and executing it as root), it will probably work. But you put a lot of trust in whoever puts this file onto that web site.






          share|improve this answer




















          • Thanks,you think that I should not install it as root before doublecheck?
            – MikiBelavista
            Mar 23 at 10:45










          • @MikiBelavista Yes. Doing something as root always needs extra attention.
            – glglgl
            Mar 23 at 11:21














          up vote
          2
          down vote



          accepted










          I don't see the relation to programming (it certainly would fit better on SuperUser or Unix/Linux), but the reason that you are denied the permission to do what you do is related to the user IDs your pipe components are executed under.



          With



          sudo a | b


          you are starting two processes, the first of them piping its output to the second one. The first one (sudo) executes another one (a) and feeds its output to b, which is executed with you UID.



          If you change the way things are done (fetching install script as "you" and executing it as root), it will probably work. But you put a lot of trust in whoever puts this file onto that web site.






          share|improve this answer




















          • Thanks,you think that I should not install it as root before doublecheck?
            – MikiBelavista
            Mar 23 at 10:45










          • @MikiBelavista Yes. Doing something as root always needs extra attention.
            – glglgl
            Mar 23 at 11:21












          up vote
          2
          down vote



          accepted







          up vote
          2
          down vote



          accepted






          I don't see the relation to programming (it certainly would fit better on SuperUser or Unix/Linux), but the reason that you are denied the permission to do what you do is related to the user IDs your pipe components are executed under.



          With



          sudo a | b


          you are starting two processes, the first of them piping its output to the second one. The first one (sudo) executes another one (a) and feeds its output to b, which is executed with you UID.



          If you change the way things are done (fetching install script as "you" and executing it as root), it will probably work. But you put a lot of trust in whoever puts this file onto that web site.






          share|improve this answer












          I don't see the relation to programming (it certainly would fit better on SuperUser or Unix/Linux), but the reason that you are denied the permission to do what you do is related to the user IDs your pipe components are executed under.



          With



          sudo a | b


          you are starting two processes, the first of them piping its output to the second one. The first one (sudo) executes another one (a) and feeds its output to b, which is executed with you UID.



          If you change the way things are done (fetching install script as "you" and executing it as root), it will probably work. But you put a lot of trust in whoever puts this file onto that web site.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Mar 23 at 10:38









          glglgl

          1,102710




          1,102710











          • Thanks,you think that I should not install it as root before doublecheck?
            – MikiBelavista
            Mar 23 at 10:45










          • @MikiBelavista Yes. Doing something as root always needs extra attention.
            – glglgl
            Mar 23 at 11:21
















          • Thanks,you think that I should not install it as root before doublecheck?
            – MikiBelavista
            Mar 23 at 10:45










          • @MikiBelavista Yes. Doing something as root always needs extra attention.
            – glglgl
            Mar 23 at 11:21















          Thanks,you think that I should not install it as root before doublecheck?
          – MikiBelavista
          Mar 23 at 10:45




          Thanks,you think that I should not install it as root before doublecheck?
          – MikiBelavista
          Mar 23 at 10:45












          @MikiBelavista Yes. Doing something as root always needs extra attention.
          – glglgl
          Mar 23 at 11:21




          @MikiBelavista Yes. Doing something as root always needs extra attention.
          – glglgl
          Mar 23 at 11:21












           

          draft saved


          draft discarded


























           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f437894%2fcannot-touch-usr-local-bin-goss-permission-denied%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          How to check contact read email or not when send email to Individual?

          Bahrain

          Postfix configuration issue with fips on centos 7; mailgun relay