Authentication failed for Azure Git

后端 未结 18 1000
攒了一身酷
攒了一身酷 2020-12-31 03:19

I\'m trying to clone my webapp in Azure.

When I run git clone https://username@appname.scm.azurewebsites.net:443/appname.git the terminal asks me for my

相关标签:
18条回答
  • 2020-12-31 04:01

    A straight forward method to get this over with is to Download/Get Publish profile (make sure you refresh the portal page) from main toolbar and use the password given in the .publishsettings file.

    0 讨论(0)
  • 2020-12-31 04:03

    None of the above solution worked for me.

    The reason why the same error was observed in my deployment was because my password contained a character "@".

    This malformed the Git clone url for my Azure web app. When I changed my password by removing @, it solved this issue. You can change @ to %40 in your connection string as well.

    0 讨论(0)
  • 2020-12-31 04:05

    Go to the Security Tab >> Personal Access Tokens >> New Toke >> Give it Full Access >> Note the Access token as you will use it as your password

    0 讨论(0)
  • 2020-12-31 04:07

    Accepted answer did not work for me but this worked.

    1. Check your set Azure URL with

      git config --get remote.<azure-remote-name>.url
      
    2. Reset azure url with following command

      git remote set-url <azure-remote-name>
      https://<user>@<sitename>[_<slotName>].scm.azurewebsites.net:443/<site>.git
      
    3. Try pushing your code using

      git push <azure-remote-name>
      
    4. It will open windows authentication screen which says to enter credential to connect to https://<user>@<sitename>[_<slotName>].scm.azurewebsites.net/<site>.git

    5. Cancel this window. It will prompt the basic credential window which says to enter credential to connect to https://<user>@<sitename>[_<slotName>].scm.azurewebsites.net:433/<site>.git

    Enter in your credential and it works.

    0 讨论(0)
  • 2020-12-31 04:07

    For me it was a matter of cloning the project with the remote url and cancelling the windows security prompt. Afterwards, it'll ask you for the password. Once you're able to clone it, you can push it successfully.

    Moral of the story: Clone it first before pushing.

    0 讨论(0)
  • 2020-12-31 04:07

    What worked for me is I created personal access token. Click username in top right corner > Security > Select Personal Access token from left pane > New Token. Provide token name and scope for your token and Click create. Save that token and use it as password.

    0 讨论(0)
提交回复
热议问题