What are cloud best practices for installing software on many EC2 instances that can be configured many ways?

0

I have a large piece of server software (3 GB of files pre-install) that is running on an EC2. The software installs a full app server or interface server that communicates with the front-end desktop GUIs and database. The software was originally designed years ago to be installed through a visual step-by-step installer off a USB drive on premises. This installer ensures that the software is set up with proper configuration, networking, connection to the database, etc. Every client gets 1 or more EC2 instances dedicated to handle their workload. Moving into a cloud-minded paradigm, what is a better way to handle creating many servers, for many clients, all with different configurations of this software? When a server goes down, or another is needed for load, what's a "cloud" practice to spin up a new server and install the same configuration of software on this server?

I have multiple ideas including:

  1. Store software files in S3 bucket and pull them to the EC2 instances as necessary. A config file for each customer will also be updated and stored on S3. The EC2 will then start the software from a PowerShell script to create proper configurations.
  2. Store the software in the AMI of EC2 exactly as configured. This means any time a server is created with a new client configuration, we create a new AMI after installation.
  3. Create a Lambda function that can handle all the different configuration parameters. When invoked, it will take care of spinning up a server, moving the software to the server, and installing the software with proper configuration.

Any guidance or references to white papers would be appreciated.

Thank you!

1 Antwort
0

Hi - You can consider to look into the following. One from an auto scaling standpoint and one from bringing up the infrastructure.

  1. A launch template is similar to a launch configuration, in that it specifies instance configuration information. It includes the ID of the Amazon Machine Image (AMI), the instance type, a key pair, security groups, and other parameters used to launch EC2 instances. For example, you can create a launch template that defines a base configuration without an AMI or user data script. After you create your launch template, you can create a new version and add the AMI and user data that has the latest version of your application for testing . More Reference : https://docs.aws.amazon.com/autoscaling/ec2/userguide/launch-templates.html
  2. Deploying applications on Amazon EC2 with AWS CloudFormation - CloudFormation includes a set of helper scripts (cfn-init, cfn-signal, cfn-get-metadata, and cfn-hup) that are based on cloud-init. You call these helper scripts from your CloudFormation templates to install, configure, and update applications on Amazon EC2 instances that are in the same template. Reference : https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/deploying.applications.html

With the software you mentioned , yes there would some sort of script or helper to do the configurations for but above ideas may also help.

You can also check Distributor, a capability of AWS Systems Manager, helps you package and publish software to AWS Systems Manager managed nodes. Reference : https://docs.aws.amazon.com/systems-manager/latest/userguide/distributor.html

profile pictureAWS
EXPERTE
beantwortet vor 2 Jahren

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen