Tentacle is the secure, lightweight, cross-platform agent for Octopus Server which turns any computer into a worker or deployment target for automated deployments and operations runbooks.
This project and everyone participating in it is governed by the Octopus Deploy Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior using the instructions in the code of conduct.
If the bug is a security vulnerability in Octopus Deploy, please refer to our security policy.
Search our public Issues repository to ensure the bug was not already reported.
If you're unable to find an open issue addressing the problem, please follow our support guidelines.
:+1::tada: First off, thanks for your contribution to Tentacle! :tada::+1:
Please create a new issue for each bug fix or enhancement. Issues in this repository are automatically used to create release notes for releases.
Please ensure every commit that hits main
links either to an issue directly, or to a PR that in turn links to an issue. Please use the appropriate keywords to close issues.
We use the Octopus Tentacle project in our private TeamCity server for automated build and test reporting status changes to pull requests.
We use the Octopus Tentacle project in our private Octopus server to deploy releases of Tentacle.
Deployments happen automatically - a merge to main
will trigger a build and a deployment - continuous delivery for the win!
For internal developers, on closing an issue, ReleaseBot will ask you for release notes.
For external developers, or if ReleaseBot fails for some reason, please add a comment to the issue Release note: XXXX
to ensure release notes are generated correctly.
We bundle Tentacle inside Octopus Server to make it super duper easy to keep Tentacle updated across entire fleets of customer installations. Choosing the version of Tentacle to bundle inside Octopus Server is currently a manual process.
To include a new version into the next Octopus Server release, update the reference in Octopus.Server.csproj. This is how we guarantee the version of Tentacle we bundle is also the version we use for all the end to end tests.
In most scenarios, Tentacle is simple to debug:
Tentacle.exe run --instance=YOUR_INSTANCE_NAME
commandCurrently we can only debug netcore apps running in WSL from VSCode, Visual Studio and Rider dont seem to have good working solutions
.vscode/launch.json
file:
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Tentacle Run command",
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build",
"program": "${workspaceFolder}/source/Octopus.Tentacle/bin/net8.0/Tentacle.dll",
"args": ["run"],
"cwd": "${workspaceFolder}/source/Octopus.Tentacle",
"console": "internalConsole",
"stopAtEntry": false
},
{
"name": ".NET Core Attach",
"type": "coreclr",
"request": "attach",
"processId": "${command:pickProcess}"
}
]
}
.vscode/tasks.json
) specifies the target framework, by including --framework=net8.0
as a build arg, otherwise VSCode will attempt to build for all frameworks in the csproj and fail on full .Net framework. the build task should look similar to:
{
"label": "build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"--framework=net8.0",
"${workspaceFolder}/source/Octopus.Tentacle/Octopus.Tentacle.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
}
The Kubernetes Agent Tentacle is a bit more complex to debug, as it normally runs inside a Kubernetes Pod. To debug it locally, you can run the setup-k8s-agent-for-local-debug.sh
script in the root of this repo which will guide you through the process of installing a specially configured kind cluster, deploying the agent to it and then scaling back the installed agent so you can run a local copy to take it's place.
NOTE: This script has only been tested on MacOS so far and requires Docker Desktop, Kubectl, Go CLI and Kind to be installed. It is also only for the Kubernetes Agent Tentacle running as a Deployment Target, not as a Worker.