Running an Octopus Tentacle inside a container may be preferable in some environments where installing one directly on the host is not an option. The currently available Octopus Tentacle Docker container can be run in either polling or listening mode.
Tentacles set up this way will run inside a container and script execution will not happen on the host itself. For this reason, Octopus Tentacles inside a container may not be appropriate for many deployment tasks.
When an Octopus Tentacle container starts up, it will attempt to invoke the
register-with command to connect and add itself as a machine to that server with the provided roles and environments. Due to some limitations in Windows Containers that have only recently been fixed and made available in the 1709 Windows release, this registration will occur on every startup and you may end up with multiple instances if you stop/start a container. Our goal is to update this image to de-register the Tentacle when the container
SIGKILL signal is passed in. In the meantime you may want to use machine policies to remove the duplicated targets.
docker run --interactive --detach ` --name OctopusTentacle ` --publish 10931:10933 ` --env "ListeningPort=10931" --env "ServerApiKey=API-MZKUUUMK3EYX7TBJP6FAKIFHIEO" ` --env "TargetEnvironment=Development" ` --env "TargetRole=container-server" ` --env "ServerUrl=http://172.23.191.1:8065" ` octopusdeploy/tentacle:3.19.2
When running an Octopus Tentacle Image, the following values can be provided to configure the running Octopus Tentacle instance.
Read Docker docs about setting environment variables.
|ServerApiKey||The API Key of the Octopus Server the Tentacle should register with|
|ServerUsername||If not using an api key, the user to use when registering the Tentacle with the Octopus Server|
|ServerPassword||If not using an api key, the password to use when registering the Tentacle|
|ServerUrl||The Url of the Octopus Server the Tentacle should register with|
|TargetEnvironment||Comma delimited list of environments to add this target to|
|TargetRole||Comma delimited list of roles to add to this target|
|TargetName||Optional Target name, defaults to container generated host name|
|ServerPort||The port on the Octopus Server that the Tentacle will poll for work. Implies a polling Tentacle|
|ListeningPort||The port that the Octopus Server will connect back to the Tentacle with. Defaults to
|PublicHostNameConfiguration||How the url that the Octopus Server will use to communicate with the Tentacle is determined. Can be
|CustomPublicHostName||If PublicHostNameConfiguration is set to
Exposed Container Ports
Read the Docker docs about exposing ports.
|10933||Port Tentacle will be listening on (if in listening mode)|
Read the Docker docs about mounting volume.
|C:\Applications||Default directory to deploy applications to|