0
votes

I am new to Jenkins CI. However the issue looks very easy enough but its not working for me. My source code is in GIT and i am using Git repository for that. I am getting the error below.

Thanks in Advance.

Started by user abc Building on master in workspace /var/lib/jenkins/workspace/Hello World

git rev-parse --is-inside-work-tree # timeout=10 Fetching changes from the remote Git repository git config remote.origin.url

Fetching upstream changes from

git --version # timeout=10 using .gitcredentials to set credentials git config --local credential.helper store --file=/tmp/git7943155421179786207.credentials # timeout=10 git fetch --tags --progress +refs/heads/:refs/remotes/origin/ git config --local --remove-section credential # timeout=10 git rev-parse refs/remotes/origin/master^{commit} # timeout=10 git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10 Checking out Revision 833228fa50173e7977b4d5ee86c1385b5c6494be (refs/remotes/origin/master) git config core.sparsecheckout # timeout=10 git checkout -f 833228fa50173e7977b4d5ee86c1385b5c6494be git rev-list 833228fa50173e7977b4d5ee86c1385b5c6494be # timeout=10 Path To MSBuild.exe: msbuild.exe Executing the command msbuild.exe NimbusAutomation.sln from /var/lib/jenkins/workspace/Hello World [Hello World] $ msbuild.exe ABCAutomation.sln Build step 'Build a Visual Studio project or solution using MSBuild' changed build result to FAILURE Build step 'Build a Visual Studio project or solution using MSBuild' marked build as failure Warning: this build has no associated authentication, so build permissions may be lacking, and downstream projects which cannot even be seen by an anonymous user will be silently skipped Finished: FAILURE

enter image description here

2
@Permian who is editing questions: thank you for taking the time to make the images appear directly in the posts. Please make sure to use the exact same link in your edit, otherwise there is ambiguity about what has changed.. I see that the new image is exactly like the previous, but it requires to open the 2 images to see that there is no difference.ghybs

2 Answers

0
votes

This can be caused by not configuring a jobs authorization policy correctly.

Check either the downstream job to see its configuration, or go to

Manage Jenkins-> Configure Global Security -> Access Control for Builds -> Configure Build Authorizations in Project Configuration

And check the global settings.

After finding the parent settings, go to the project giving the error select the same configuration in the section that looks like :

enter image description here

If this still does not work, you might also need to make sure that the user has the adequate permissions if you are using matrix based security.

Manage Jenkins-> Configure Global Security -> Authorization 

And in the authorization matrix make sure the necessary user has build permissions

See also

Authorize project plugin

How To Configure Access Control For Builds

-1
votes

Thanks. I did all the advised settings above, it only resulted in Warning message to disappear, the build still fails. The build works fine on my local Command prompt when i pass - msbuild.exe NimbusAutomation.sln but still fails on jenkins...

Path To MSBuild.exe: msbuild.exe Executing the command msbuild.exe msbuild.exe NimbusAutomation.sln NimbusAutomation.sln from /var/lib/jenkins/workspace/Hello World [Hello World] $ msbuild.exe msbuild.exe NimbusAutomation.sln NimbusAutomation.sln Build step 'Build a Visual Studio project or solution using MSBuild' changed build result to FAILURE Build step 'Build a Visual Studio project or solution using MSBuild' marked build as failure Finished: FAILURE