question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

No executable found matching command "dotnet-lambda"

See original GitHub issue

I’m not sure the exact cause of this issue but let me describe what I’m seeing in case others are running into this issue. First off, I’m trying to use this extension on my “build machine” which in this case happens to be a Jenkins Slave, a Windows Server 2016 standard.

When I run the command locally, and directly in the Cmd window… dotnet lambda deploy-function --profile sandbox … everything works perfectly. However, when I run this same command from my Jenkins (which generates and deploys the script as a .bat file) I get the error No executable found matching command "dotnet-lambda

Some facts

  • I’m logged on as the same user as the Jenkins Windows service
  • I’ve already installed the tools (obviously)
  • I’m located in the same directory as the .csproj file … this error happens with donet lambda help BTW

Work Around While reading through a very similar issue (https://github.com/ElectronNET/Electron.NET/issues/189) I learned that the actual exe lives at c:\users\{username}\.dotnet\tools\dotnet-lambda.exe. Therefore I was able to work around this by manually calling the exe like

"%USERPROFILE%\.dotnet\tools\dotnet-lambda.exe" deploy-function --profile %AwsProfileName%

As I mentioned, I’m not sure this is actually an issue with this project or somehow related to the way Jenkins is running the bat file, etc.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

3reactions
ebol2000commented, Jun 13, 2019

Actually I did run the command dotnet tool install --global Amazon.Lambda.Tools just before this call and it responded that it was already installed. So in this case the extension exe is just not resolving for some reason. This is why when I call the extension exe directly it works fine.

1reaction
normjcommented, Jun 13, 2019

When you call dotnet tool install --global Amazon.Lambda.Tools or some other global tool it ensure the dotnet tools folder is part of the PATH but in your case Jenkins would need to be restarted to pick up the change to the environment variable.

Read more comments on GitHub >

github_iconTop Results From Across the Web

No executable found matching command "dotnet-lambda" ...
So I use Travis CI and dotnet lambda, and below one of the stage: script: - echo "Deploy to AWS" - dotnet tool...
Read more >
Deploying to AWS Lambda from Visual Studio Team ...
No executable found matching command "dotnet-lambda". install Amazon.Lambda.Tools to the gloable, you can build it anywhere
Read more >
No executable found matching command "dotnet-lambda"
When packaging up a dotnetcore lambda function for deployment to AWS, you could get the following error 'No executable found matching ...
Read more >
Troubleshoot .NET tool usage issues
NET runtime wasn't found. Executable file not found. If the executable file isn't found, you'll see a message similar to the following:.
Read more >
How to fix "no executable found matching command "dotnet-ef ...
I got the following error: “No parameterless constructor was found on 'TContext'. Either add a parameterless constructor to 'TContext' or add an implementation ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found