I want to gzip the JavaScript, HTML, CSS in my war before it goes over the wire. standard web stuff. Beanstalk uses an AMI to scale up.
I see the directions on how to create a new AMI, but I don’t even see where Tomcat is located. The current AMI as of this writing is ami-1a249873 for Tomcat 7 deployments.
I’ll answer this myself. Just so its clear to everyone, you CAN connect to your instances of EC2 even though they are being managed by beanstalk. This is helpful because you get to see where things are located. In this case, I didn’t know Apache was being used as the webserver for tomcat and had to search for that, but you can find it here as today:
/etc/httpd
Per making changes once you find info like this:
http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/customize-containers.html
If you create a folder called .elasticbeanstalk at the root of your project and then create a file called myapp.config.
Setup Apache:
Then create enabledeflate.conf with something like this:
A couple of notes:
You may need to restart apache the first time you deploy this.
Make sure you put .elasticbeanstalk in the root of your war file (or git repo)