<p>I was using azure-pipelines.yml for Azure Pipelines' Build. I included below scripts to make Artifact already which is used for Pipelines' Release. </p>

<pre><code># publish artifacts
- powershell: gci env:* | sort-object name | Format-Table -AutoSize | Out-File $env:BUILD_ARTIFACTSTAGINGDIRECTORY/environment-variables.txt

- task: PublishBuildArtifacts@1
  inputs:
    pathtoPublish: '$(Build.ArtifactStagingDirectory)'
    artifactName: drop1
- task: DownloadBuildArtifacts@0
  inputs:
    buildType: 'current'
    downloadType: 'single'
    artifactName: 'drop2'
    downloadPath: '$(System.ArtifactsDirectory)'
</code></pre>

<p>What should I set for Command under "Deploy to Kubernetes"?</p>

<p>How can I upload kubernetes .yaml file from GitHub to Artifacts? (what is script in azure-pipelines.yml?)</p>

DaiKeung
<p>You can also add additional type of task to your existing Azure Build Pipeline, that will download another git repository content (your kubernetes.yaml files) in addition to default source, like this one:</p>

<pre><code>- task: fakhrulhilal-maktum.GitDownloader.git-downloader.GitDownloader@0
</code></pre>

<p>It should put your GitHub repo content to $(Build.Repository.LocalPath), from where you can push it via another powershell-like task to <code>$(Build.ArtifactStagingDirectory)</code>, like other community members mentioned.</p>

<p>Please note that <a href="https://marketplace.visualstudio.com/items?itemName=fakhrulhilal-maktum.GitDownloader" rel="nofollow noreferrer">fakhrulhilal-maktum.GitDownloader.git-downloader.GitDownloader</a> is a custom task, so you will need first to install it to your DevOps Azure project.</p>
