Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am using AWS Elastic Beanstalk, it is easy to start with deploying Java based web app, which is great.

However, I want to install Memcached on every instance locally so they can be used for caching, but seems it validated the principle of Elastic Beanstalk?

Is it possible to deploy memcached locally and automatically, together with Elastic Beanstalk's auto scale feature?

(I know I can use Elastic Cache but want to save some money but still take the advantage of auto scaling)


share|improve this question
up vote 5 down vote accepted

The possibility to customize your environments is indeed one of the key characteristics of AWS Elastic Beanstalk in comparison to other PaaS offerings:

Most existing application containers or platform-as-a-service solutions, while reducing the amount of programming required, significantly diminish developers' flexibility and control. [...] However, with Elastic Beanstalk, you retain full control over the AWS resources powering your application. If you decide you want to take over some (or all) of the elements of their infrastructure, you can do so seamlessly [...]

What you are looking for is possible by facilitating a Custom AMI. Once you have launched an environment, you can customize its configuration details, amongst those the AMI used by your instances as illustrated in Configuring Servers. While there are some requirements to be met in order to properly execute within Beanstalk, you can basically customize these AMIs to your heart's content, the process is documented in Using Custom AMIs (for a 3rd party explanation see e.g. How to customize an Amazon Elastic Beanstalk instance).

Please be aware of the following implication though:


After you are running on your own custom AMI, you will no longer receive any automated updates to the operating system, software stack, or the AWS Elastic Beanstalk host manager.

This means you will need to track the evolution of the AWS AMIs yourself to ensure stability and security of your application - this isn't as easy as it should be currently, as discussed e.g. in Amazon AMI product lifecycle questions and more recently Keeping up with the AWS Developers (Latest AMI's).

Good luck!

share|improve this answer

You can now configure AWS Elastic Beanstalk using configuration files. This is an alternative to creating and maintaining custom AMIs.

It is currently supported on Tomcat 6/7, Python 2.6, and Ruby 1.8.7/1.9.3.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.