Updating a web app via azure pipelines and FTP

Kev Martin 0 Reputation points
2025-05-02T21:21:21.6833333+00:00

Hello

When I update spicetheworld.com from within Visual Studio with these creds it all goes well

User's image

However when I try to update spicetheworld.com from a azure pipeline

Test 1

      - task: FtpUpload@2
        displayName: 'FTP Upload'
        inputs:
          credentialsOption: inputs
          serverUrl: 'ftp://ftp.spicetheworld.com'
          username: azure
          password: ##########
          rootDirectory: '$(build.artifactstagingdirectory)'
          remoteDirectory: '/'
          trustSSL: true
          clean: true
          preservePaths: true

I get User's image

Test 2

- task: FtpUpload@2
        displayName: 'FTP Upload'
        inputs:
          credentialsOption: inputs
          serverUrl: 'ftp://ftp.spicetheworld.com'
          username: azure
          password: ##########
          rootDirectory: '$(build.artifactstagingdirectory)'
          remoteDirectory: '/spicetheworld.com'
          trustSSL: true
          clean: true
          preservePaths: true

User's image

However instead of updating the folder /spicetheworld.com this has created a new folder structure /spicetheworld.com/spicetheworld.com/SpiceTheWorld and the visible site is not updated.

To confirm the FTP user is called azure and the root folder for this user is /spicetheworld.com

Any ideas on where I am going wrong please

Azure DevOps
0 comments No comments
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.