vaadin 24.0.0.alpha8 PreRelease build error on azure agent - vaadin

We have recently tried to do an experimental upgrade to vaadin 24 PreRelease version. We were able to build and run the application in local environment but the application fails to build on azure agent with below error:
[ERROR] Failed to execute goal com.vaadin:vaadin-maven-plugin:24.0.0.alpha8:build-frontend (default) on project rmod-tools: Execution default of goal com.vaadin:vaadin-maven-plugin:24.0.0.alpha8:build-frontend failed: Unable to validate the license, please check your internet connection. If you need to work offline then please go to https://vaadin.com/pro/validate-license?getOfflineKey=mid-abfe707e-8d41af4e to retrieve an offline key. For troubleshooting steps, see https://vaadin.com/licensing-faq-and-troubleshooting.
The application builds successfully in local env.

Related

TFS 2017 + Sonarqube

We have a on prem installation of TFS (TFS 2017) and I am attempting to integrate SonarQube analysis into our build steps. I have installed the SonarQube extension on the TFS server and added a service endpoint to point to a server where I have SonarQube Server installed and configured.
When I attempting to trigger a build, I am getting an error "No agents could be found with the following capabilities: msbuild, java, visualstudio". Does my build server need JRE to be installed to get the SonarQube build steps to work? SonarQube website says this:
**Installation
Make sure the .NET Framework v4.5.2+ is installed
Make sure the Java Runtime Environment 8 is installed
Install the extension from the marketplace**
Both the error message and the documentation told you the same thing: You need Java installed.
I will be the third source of confirmation: You need Java installed.
First, the official document is very clear here: Make sure the Java Runtime Environment 8 is installed
Besides, according to your prompting error message:
No agents could be found with the following capabilities: msbuild,
java, visualstudio
You are also lacking msbuild, visualstudio. Not only need Java installed, but also need Visual Studio installed on your build agent, then restart the build agent. Restarting the build agent will capture the added Capabilities. If this not work, reconfigure the build agent should do the trick.
The build agent will not detect the environment changes after you installed it. It will only detect during the installation. If you are using vNext build agent, also try to manually add some capabilities in Settings- Agent Queues- Agent Pool - Agent- Capabilities. After this trigger the build again.
Note: if you are running on TFS earlier than 2017 Update 2, you will need to download and manually install the latest 3.x version of the VSIX to install SonarQube Extension.

restore nuget in jenkins

When I tried to use Jenkins as our CI environment to build ASP.NET project, I set up to use MSBuild.exe to build project. But when the cmd run into restore nuget packages, it stuck. The error message is as below:
Unable to find version '2.5.48' of package 'SlowCheetah'.
https://api.nuget.org/v3/index.json:
Unable to load the service index for source
https://api.nuget.org/v3/index.json.
An error occurred while sending the request. Unable to connect to the remote server.
A socket operation was attempted to an unreachable network
[2606:2800:133:206e:1315:22a5:2006:24fd]:443
But if I use windows command line to run the msbuild, it is working and could download the pkg from nuget.org. Error only happened when try to build in Jenkins
NB : jenkins is running like a windows service and he is used by an administrator account

TFS Build Server gives service unavailable (503) message

I recently installed TFS 2015 on a new machine. I want to configure the same machine as our build server but i have massive trouble doing this. I neither can configure the new vNext-system nor can i configure an "old-style" xaml build server. As the build account i want to use the NT AUTHORITY\Network Service. For the xaml configuration i set "Execute service as" to NT AUTHORITY\Network Service and use the same account for the connection to the team foundation server.
But when i add a new controller and want to browse to custom assemblies, i get a "service unavailable" error. So i decided to test without the custom assemblies, added an build agent and created a new build-definition for a simple test project. I added a build to the queue and wait. Nothing happenend (in the build window) until after about 50 seconds an error was shown in the build window: Service Unavailable (Typ VssServiceResponseException).
Same for the new vNext builds. I downloaded the agent.zip from the web-frontend, opened the powershell and started configuring the build-agent. After waiting some minutes, the configuration aborted with.... service unavailable.
So i decided to test something different : instead of using the FQHN, i used localhost and - tataaa - it starts the agent, which is also shown green in the web-frontends agent-tab. So i created a new vNext-Build-Definition and added it to the queue, but it does not start, but shows the message : "waiting for console output from an agent".
So i decided to test it on a different pc : i downloaded the agent to my laptop and installed it, configuring the agent with it's FQHN. Without any problems the agent was started and i was able to start and run a build.
So the question is : Why am i'm not able to configure the build service on the tfs. I guess it has something to do with permissions, but i don't now, what permissions the network service account should have. I also tried it with a local account, but with the same result.
Any hints are very appreciated. Thanks in advance.
BTW: I can ping the FQHN from the command-line.
This is the output, after trying to add a vNext-agent via the powershell.
UPDATE:
I used the the servers IP-address instead of its name and it suddenly worked.
Take XAML build for example, to configure a Team Foundation Build Service, you must be a member of both the Windows Administrators security group on the server on which you are configuring Team Foundation Build Service and the Project Collection Administrators group on TFS.
According to the second paragraph, you can configure build controller and add build agent. Before queuing a build, you need to make sure the build controller and agent are in Ready status, sometimes relevant services are not yet fully available when you newly configure them or restart them.
Also, you may try to remove build service feature, and reconfigure it, to see whether you can solve the issue.

Can't install TFS 2015 build vNext agent as a service

I'm looking at migrating our builds from the old XAML to the new build system, but I have a problem with configuring the build agent to run as a service.
Configuring the agent to run interactively (in my session on the build server) works. The builds are OK but this is not useable as I have to open a session and start the agent.
Configuring the agent to run as a service with the default NT AUTHORITY\NETWORK SERVICE works. The builds are broken. WiX doesn't like this account and fails during the ICE validation. The drop also fails because this account doesn't have access to the drop folder.
Configuring the agent to run as a service with a domain account fails. The service is not created and I get the following error:
Installing service vsoagent.tfs-server.tfs-build-server-agent1...
Creating EventLog source vsoagent.tfs-server.tfs-build-server-agent1 in log Application...
An exception occurred in the OnAfterInstall event handler of System.ServiceProcess.ServiceInstaller.
System.NullReferenceException: Object reference not set to an instance of an object.
The username and passwords are OK, I get a different "bad username or password" error when typing a bad password. The user was used for the old XAML build system on the same build server and is in the local admin group, so it has authorisations AFAIK.
I was running TFS 2015, I upgraded to 2015 update 1 then forced an agent update in the web interface. After that it works, I can configure the agent to run as a service using a domain account.
Agent.Version is still saying 1.83.2 in the web interface, but the files are actually different in the agent folder. An agent.old folder is left after the upgrade and you can see that VsoAgent.exe and VsoAgentService.exe have a different size and version. Also the agent.old folder has 138 files in 46 folders, but the agent folder has 157 files in 53 folders.
I Had the same issue with the WIX validation. But i did not try to reconfigure the agent (not due to problems,just due to pure laziness), instead i did just change the account to a domain account using the services overview. restarted the machine and everything did work fine.
To narrow down your issue:
1.Try to Configure the agent to run as a service with another domain account on another computer
2.If you need to change the logon account, don't do it from the services snap-in. Instead, From an elevated Command Prompt, run: C:\Agent\Agent\VsoAgent.exe /ChangeWindowsServiceAccount
update
If you upgrade your TFS2015 to TFS2015update1. Do not just use the simple update agent in the web interface. You need download the agent from web and reconfigure it in the cmd.

EXEC: Unable to connect to the remote server on NuGet restore on TFS build server

I am trying to use NuGet restore to pull the packages on the TFS build process, however, it keeps giving out the error EXEC: Unable to connect to the remote server
If I manually execute the MsBuild MyProjet.sln, it will build without issues.
Any help will be greatly appreciated.
It turns out that TFS service is running at a different account than my own account. After log on as the TFS account and turned on proxy server for that account, NuGet is able to download the package and finish the build.

Resources