Amazon Web Services Beanstalk deployment using Octopus Deploy

(John Ponnampalam) #1

We are trailing Octopus Deploy as the tool for deployment to AWS Beanstalk. We use TFS Online Build which pushes the nuget package to The Octopus server then uses this repository for deploying builds.
I have read the following support issue:
and also this code project article:-

I am still not clear how it works. My questions are:-

  1. Since Beanstalk is auto scaling the exact servers may vary. The AWS Deployment with Octopus article suggests a AWSDeploy command to be executed which will install Tentacle on the servers created by Beanstalk in Listening mode. It appears to me that a deployment power shell script calling AWSDeploy should be run from Octopus Server each time a new/updated package is arrives from TFS daily build. If this is the case why bother with Tentacles? Wouldn’t the AWSDeploy command executed on the Octopus Server do all the software updates on the elastic servers it creates and destroys based on auto scaling?

  2. Could you give me some details on how the deployment from octopus server to beanstalk works and what steps need to be taken?

Thanking you in advance,


(Damian Maclennan) #2

Hi John

Thanks for getting in touch and sorry for the delay in responding, Elastic Beanstalk isn’t an area we have lots of experience in so I’ve been doing some research of my own.

So to try to answer your questions.

  1. When a machine is provisioned, it will have a tentacle installed with environment and role parameters configured and registered with the Octopus Server. At that time, it will query the Octopus Server for the latest release and initiate a deployment.

Future releases will be installed by the Octopus Server contacting the tentacle directly, and not using AWSDeploy. If you read part 1 to the Code Project article ( , which is excellent by the way) the author explains the problems with AWSDeploy, mainly the non-deterministic way it pushes releases as well as the inflexibility in configuring your application.

Essentially the answer to your question is that in a new release, the Octopus Server is calling a tentacle to do the deployment rather than AWS Deploy.

Does that make sense ?

  1. The article you linked to does a great job of explaining things as far as I see it. I’m not sure I could do a better job here. Can I ask that you experiment with those steps and let me know if you get stuck on a particular issue ?

I did experiment with a simpler approach where we used a local tentacle to push the files directly to AWS, but the lack of configuration options makes that a not particularly useful solution.

Hope that helps somewhat, please do get in touch if it’s still unclear.



(John Ponnampalam) #3

Hi Damian,
Thanks for the update. Your response has made it clearer. In my beanstalk installation I have configured a minimum of 2 and max of 4 AMI instances.
So my follow up question is :-
When a machines is provisioned by AWS I will supply the power shell script which will install Tentacle. Am I right in assuming if Tentacle is configured as a Listening Tentacle and the Octopus Server IP and Thumbprint is set up then on provisioning the Tentacle instance connects to the server for an update and thereafter the Octopus Server will push updates to the Tentacle when a Deploy/Release action is initiated ?

(Damian Maclennan) #4

Hi John

Yep I think you’ve got it.
The only thing to be wary of is the cleanup of deprovisioned machines, there is a script in the CodeProject article. It’s not an ideal situation and something we want to improve in the future but having a bunch of offline machines will slow down Octopus as all those health check tasks get requeued.



(John Ponnampalam) #5

Hi Damian,
Thanks. I am going through a demo scenario to determine if Octopus is the right corporate deployment too for us. Looks good so far.


(Damian Maclennan) #6

Hi John

That’s great news.
Let me know if you have any further questions that we can help with.



(system) closed #7