/OctopusTentacle

| Public | 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.

Primary LanguageC#Apache License 2.0Apache-2.0

Tentacle

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.

Tentacles Everywhere

Code of Conduct

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.

Did you find a bug?

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.

Contributing

Issues, Pull Requests, and Release Notes

👍🎉 First off, thanks for your contribution to Tentacle! 🎉👍

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.

Build, Test, and delivery

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.

Bundling Tentacle with Octopus Server

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.

Debugging

In most scenarios, Tentacle is simple to debug:

  1. Just like a customer, set up an instance of Tentacle and connect it to an Octopus Server
  2. Start Tentacle using the debugger in your development environment of choice, using the Tentacle.exe run --instance=YOUR_INSTANCE_NAME command

Debugging in WSL (Windows Subsystem for Linux )

Currently we can only debug netcore apps running in WSL from VSCode, Visual Studio and Rider dont seem to have good working solutions

{
    // 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/net6.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}"
        }
    ]
}
  • Make sure the build task (in .vscode/tasks.json) specifies the target framework, by inclusing --framework=net6.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=net6.0",
        "${workspaceFolder}/source/Octopus.Tentacle/Octopus.Tentacle.csproj",
        "/property:GenerateFullPaths=true",
        "/consoleloggerparameters:NoSummary"
    ],
    "problemMatcher": "$msCompile"
}

Additional Resources

  • Scripts to help with manual testing can be found in ./testing.