I have a server which is registered with an Azure DevOps Pipeline Environment which has come up in a security scan that a few npm packages used by CopyFiles task have vulnerabilities. The version of the task on the server is 2.246, checked the latest version 2.256 & it seems like the packages have been updated.
My problem is I can't seem to get the deployment job to download a latter version than [email protected], I've deleted the task to which causes a redownload of v2.246.
I've updated the pipeline to specify [email protected] but still downloaded v2.246.
How do I update the copy files task to a newer version?
Deployment job YAML below besides paths.
- deployment: DeployJob
dependsOn: CreateArtifactJob
condition: eq(variables['Build.SourceBranch'], 'refs/heads/main')
workspace:
clean: all
environment:
name: Asset
resourceType: virtualMachine
strategy:
runOnce:
deploy:
steps:
- task: CopyFiles@2
displayName: 'Copy website'
inputs:
SourceFolder: '$(Pipeline.Workspace)\Artifact\subfolder\'
Contents: '**'
TargetFolder: 'dest path'
OverWrite: True
- task: CopyFiles@2
displayName: 'Copy application'
inputs:
SourceFolder: '$(Pipeline.Workspace)\Artifact\subfolder\'
Contents: '**'
TargetFolder: 'dest path'
OverWrite: True
Edit: We use Azure DevOps Services.
https://dev.azure.com/<your-org>/_apis/distributedtask/tasks?api=verion=7.0? Please provide more information about your self-hosted build agent.