Follow

Deploy the Alert Logic Agent in AWS Elastic Beanstalk | How To

Overview

Amazon Web Services (AWS) Elastic Beanstalk is a service designed to allow customers to deploy and manage applications that are running in AWS without needing to configure the underlying infrastructure that the applications run on.

Alert Logic fully supports agent deployment on Elastic Beanstalk. As with traditional EC2 instances, you can install the Alert Logic agent via SSH and command line, but also have the ability to add the Alert Logic agent into your Elastic Beanstalk application bundle. This allows for the auto-deployment of the Alert Logic agent in your Elastic Beanstalk deployment. By following the process below, you can automate installation in your existing deployment and ensure successful application bundle updates.

Solution

The following configuration steps are defined using config files within a directory called .ebextension that needs to be added to the application bundle. By adding these installation steps to configuration files within the .ebextension directory, Alert Logic agents can be deployed into Elastic Beanstalk environments.

NOTE: Use caution when creating or editing these files. The service is very sensitive to MSDOS/Windows line breaks. If using YAML, remember that tabs are considered invalid characters and will cause the environment to fail. Mac users must use the command-line "zip" and not the Finder-integrated "Compress" option.

The following examples demonstrate how to install and provision the Alert Logic agent for both Linux and Windows instances deployed in your AWS Elastic Beanstalk environment.

Linux Deployment

In this example, the standard Java with Tomcat sample application (http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/samples/java-tomcat-v1.zip) is used. The steps are identical for other application bundles.

  1. Unzip the application bundle into a directory.

  2. If the base directory does not already contain a .ebextension directory, create one.

    NOTE: The period at the beginning of the directory name indicates that this directory is meant to be hidden.

  3. Call the configuration options within the .ebextension directory. The configuration options are defined in .config files and must be either JSON or YAML. The name of the file does not matter, as long as the file extension .config is used. The example below uses "alagent.config".

    eb.png

  4. Once you've added the config file, create a new application bundle, as the command line zip tool will not include hidden directories unless explicitly directed. Make sure your output includes the .config file you specified. Utilize the following example as a guide:

    eb2.png

You can now upload and deploy the new version of the application bundle, which will download and provision the agent.

Windows Deployment

In this example, the standard IIS-DotNet sample application is used. The steps are identical for other application bundles.

  1. Unzip the application bundle into a directory.

  2. If the base directory does not already contain a .ebextension directory, create one.

    NOTE: The period at the beginning of the directory name indicates that this directory is meant to be hidden.

  3. Call the configuration options within this directory. The name of the file does not matter, as long as the file extension .config is used. The example below uses "alagent.config".

    eb3.png

  4. Once you've added the config file, create a new application bundle.

You can now upload and deploy the new version of the application bundle, which will download and provision the agent.

Was this article helpful?
0 out of 1 found this helpful
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.