Unable to run Calamari on SSH Deployment Target

I’ve set up an Alpine Linux Docker image with NGINX, SSH and Bash and want it as a Deployment Target for Octopus Deploy. When I attempt to deploy to the server, I get the following error message, however:

/home/octopus/.octopus/OctopusServer/Work/20180311213354-253-43/command.sh: line 17: /home/octopus/.octopus/OctopusServer/Calamari/linux-x64/4.4.4/Calamari: No such file or directory
The remote script failed with exit code 127
The action Copy web on Staging Server failed

I’ve shushed into the server and checked whether /home/octopus/.octopus/OctopusServer/Calamari/linux-x64/4.4.4/Calamari exists, and it does. The log is very sparse and I have no idea what exit code 127 means.

Can you please give me some clues on what might be the problem here?

After installing Mono in the Docker image, the Deployment Target started working correctly, but it would be nice if Mono wasn’t required. You can reproduce the Calamari problem by booting this Dockerfile and adding it as an SSH Deployment Target in Octopus Deploy. The username is octopus and the password is OpenSesame.

Hi Asbjørn,

Thanks for getting in touch!

Octopus supports both Mono and .NET Core variants of Calamari for SSH targets. Looking at the initial file path that you had it appears that you started with our .NET Core variant and had to switch to the Mono version for this install to work. Can you confirm that this is the case?

Assuming that is the case, can you confirm that you have all of the .NET Core prerequisites installed on this image. If that is the case so that we can try and diagnose further are you able to delete the /home/octopus/.octopus/OctopusServer/Calamari directory, retry a deployment and attach the raw task logs from that deployment?

You may need to switch your install back to .NET Core from Mono prior to the deployment, this can be done on your Infrastructure > Deployment Targets page, selecting the target then scrolling down to the .NET section

While I would have loved to pull down the docker image you provided to do the testing myself unfortunately docker is not my area of expertise and I didn’t have time to get up to speed before replying to you. Definitely on my radar though!


You are correct in all of your assumptions. I did not have the .NET Core prerequisites installed. I can see that there’s Alpine builds of microsoft/dotnet-nightly, but I can’t find Alpine builds of the stable microsoft/dotnet/. Any idea what I Docker image I should base my Deployment Target on? I’ll try microsoft/dotnet-nightly:2.1-runtime-alpine for now and will report back the result.

Ok, I’ve configured the Deployment Targets to “Mono not installed (beta)” and tested with dotnet-nightly:2.1-runtime-alpine. That just led to the same error as originally:

/home/octopus/.octopus/OctopusServer/Work/20180312111216-294-124/command.sh: line 17: /home/octopus/.octopus/OctopusServer/Calamari/linux-x64/4.4.4/Calamari: No such file or directory

It is very adamant about installing Calamari. This is the first few lines from the log (just before the error):

This server does not have version 4.4.4 of the Calamari package. It will be pushed automatically. 
Extracted Calamari to /home/octopus/.octopus/OctopusServer/Calamari/linux-x64/4.4.4
Calamari.linux-x64 upgrade successful

The distro I have successfully used is CentOS 7.

I haven’t tried using a container as deployment target but I can’t see why that’d be a problem. Would it be possible to target CentOS? It might be required to have libuv and libunwind installed. Can’t recall now if Octopus has those on its self contained installation. Might not be related to your issue but could work out.
Hope it helps.

Hi @asbjorn_ulsberg, could we get a copy of those raw task logs that @Alex.Rolly mentioned to help diagnose what could be going on.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.