You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
got this successful build pipeline which just compile 2 projects from diferent repos ( the first one from GH and the another from current master devops repo) all is fine but at the end the fist one deploy built artifcat (compiled project) right in the container, however the second checkout deploy the built artifact but the previous one as well. why? i tried diferent approaches without luck...
In below YAML what it does is the folllowing:
-compile and deploy built artifact from the repo of GH
-And then compile and deploy the built artifact from the repo of master in devops.
*****All works well but when I see the 2 separates built artifacts containers the first one is fine which contain the built artifact for GH , but the second Artifact container contain both projects ( both built artifacts) would you know why? I added clean=true to each check out but remains the same… I also tried to add the solution path but it doesn´t find it.
script: echo "Uploading Artifact of remote github project"
displayName: Printing a message.... "NEXT TASK IS TO UPLOAD ARTIFACT OF HITHUB REPO HERE*......."
But it uploads both built artifacts for both repos into the last one .
The first one upload the built artifact well. Why ?
I added the clean = true to each checkout
the first check out uploads the right built artifact to container
Goal :
The only artifact that should upload to DevopsARTIFACTS2 IS webapplication1. ( not included with the previous built artifact which was for GHartifact1 (webapplication2).).
Any pointers would be much appreciated
In case anyone would like for me to add you as contributor to my devops project let me know.
we need to each built artifacts only deploy the right project not both on the same.
The text was updated successfully, but these errors were encountered:
if you found a better workaround for using one job for many checkouts and upload each deployed artifact it`s corresponding built artifact accordingly , please detail here the steps. thanks.
got this successful build pipeline which just compile 2 projects from diferent repos ( the first one from GH and the another from current master devops repo) all is fine but at the end the fist one deploy built artifcat (compiled project) right in the container, however the second checkout deploy the built artifact but the previous one as well. why? i tried diferent approaches without luck...
In below YAML what it does is the folllowing:
-compile and deploy built artifact from the repo of GH
-And then compile and deploy the built artifact from the repo of master in devops.
*****All works well but when I see the 2 separates built artifacts containers the first one is fine which contain the built artifact for GH , but the second Artifact container contain both projects ( both built artifacts) would you know why? I added clean=true to each check out but remains the same… I also tried to add the solution path but it doesn´t find it.
YAML file
trigger:
resources:
repositories:
- repository: testcheckout
type: github
endpoint: github.com_msdansau
name: msdansau/testcheckout
- repository: checkout_toGH_repo
type: git
name: checkout_toGH_repo/checkout_toGH_repo
ref: main
trigger: none
pool:
vmImage: 'windows-latest'
variables:
solution: '**/*.sln'
buildPlatform: 'Any CPU'
buildConfiguration: 'Release'
steps:
task: NuGetToolInstaller@1
- checkout: testcheckout
clean: true
task: NuGetCommand@2
inputs:
restoreSolution: '$(solution)'
task: VSBuild@1
inputs:
solution: '$(solution)'
msbuildArgs: '/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:DesktopBuildPackageLocation="$(build.artifactStagingDirectory)\WebAppGH.zip" /p:DeployIisAppPath="Default Web Site"'
platform: '$(buildPlatform)'
configuration: '$(buildConfiguration)'
task: VSTest@2
inputs:
platform: '$(buildPlatform)'
configuration: '$(buildConfiguration)'
script: echo "Uploading Artifact of remote github project"
displayName: Printing a message.... "NEXT TASK IS TO UPLOAD ARTIFACT OF HITHUB REPO HERE*......."
task: PublishBuildArtifacts@1
inputs:
PathtoPublish: '$(Build.ArtifactStagingDirectory)'
ArtifactName: 'GHartifact1'
publishLocation: 'Container'
script: echo "CHECKOUT DEVOPS REPO NOW..."
displayName: Printing a message.... "CHECKOUT DEVOPS REPO.............."
checkout: checkout_toGH_repo
clean: true
persistCredentials: true
path: checkout_toGH_repo
task: NuGetCommand@2
inputs:
restoreSolution: '$(solution)'
task: VSBuild@1
inputs:
solution: '$(solution)'
msbuildArgs: '/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:DesktopBuildPackageLocation="$(build.artifactStagingDirectory)\WebAppdevops.zip" /p:DeployIisAppPath="Default Web Site"'
platform: '$(buildPlatform)'
configuration: '$(buildConfiguration)'
task: VSTest@2
inputs:
platform: '$(buildPlatform)'
configuration: '$(buildConfiguration)'
task: PublishBuildArtifacts@1
inputs:
PathtoPublish: '$(Build.ArtifactStagingDirectory)'
ArtifactName: 'DEVOPSaRTIFACT2'
publishLocation: 'Container'
alls works well
![image](https://user-images.githubusercontent.com/92469585/227379245-486899d4-108f-4aaf-870d-34512d08a9a5.png)
But it uploads both built artifacts for both repos into the last one .
The first one upload the built artifact well. Why ?
I added the clean = true to each checkout
the first check out uploads the right built artifact to container
![image](https://user-images.githubusercontent.com/92469585/227379457-a5b4dbcf-e92c-4aa7-82a2-0c4f2706eeb3.png)
Goal :
The only artifact that should upload to DevopsARTIFACTS2 IS webapplication1. ( not included with the previous built artifact which was for GHartifact1 (webapplication2).).
Any pointers would be much appreciated
In case anyone would like for me to add you as contributor to my devops project let me know.
we need to each built artifacts only deploy the right project not both on the same.
The text was updated successfully, but these errors were encountered: