2

I have setup travis-ci to deploy to azure website, travis use dpl for deployment, but I get unable to resolve host:

fatal: unable to access 'https://username:!password@https://test-ci.azurewebsites.net/.scm.azurewebsites.net:443/https://test-ci.azurewebsites.net/.git/': Couldn't resolve host 'https'

but the actual git url at azure portal is:

https://username@test-ci.scm.azurewebsites.net:443/test-ci.git
zx8754
  • 52,746
  • 12
  • 114
  • 209
Alvin
  • 8,219
  • 25
  • 96
  • 177

2 Answers2

0

As my test, we only need to provide the site name to the .travis.yml file. It is enough (do not use web app url or git url as the value of site). The following is my deploy part in .travis.yml.

deploy:
  provider: azure_web_apps
  username: "jambor1"       # If AZURE_WA_USERNAME isn't set
  password: "***"   # If AZURE_WA_PASSWORD isn't set
  site: "travistestja"       # If AZURE_WA_SITE isn't set
  verbose: true

Here is the result:

enter image description here

Jambor - MSFT
  • 3,175
  • 1
  • 13
  • 16
0
  1. when you are creating deployment credentials don't use '@' character or other special characters which will break the git repository path created by azure local git deployment.

  2. Follow article https://learn.microsoft.com/en-us/azure/app-service-web/scripts/app-service-powershell-deploy-local-git where you will see that git is using username and password both for connecting to git repository, so if there are some difference in actual repository path in azure portal and in travis ci that is not the actual problem.

Manish
  • 1
  • 1
  • 2
    Welcome to Stack Overflow! Whilst this may theoretically answer the question, [it would be preferable](//meta.stackoverflow.com/q/8259) to include the essential parts of the answer here, and provide the link for reference. – GhostCat Aug 14 '17 at 17:30