Static Web Server AWS OpsWorks Stacks Layer
Important
AWS OpsWorks Stacks is no longer accepting new customers. Existing customers will be able to use the OpsWorks console, API, CLI, and CloudFormation resources as normal until May 26, 2024, at which time they will be discontinued. To prepare for this transition, we recommend you transition your stacks to AWS Systems Manager as soon as possible. For more information, see AWS OpsWorks Stacks End of Life FAQs and Migrating your AWS OpsWorks Stacks applications to AWS Systems Manager Application Manager.
Note
This layer is available only for Linux-based stacks.
The Static Web Server layer is an AWS OpsWorks Stacks layer that provides a template for instances to serve
static HTML pages, which can include client-side scripting. This layer is based on
Nginx
Installation: Nginx is installed in
/usr/sbin/nginx
.
The Add Layer page provides the following configuration options:
- Custom security groups
-
This setting appears if you chose to not automatically associate a built-in AWS OpsWorks Stacks security group with your layers. You must specify which security group to associate with the layer. For more information, see Create a New Stack.
- Elastic Load Balancer
-
You can attach an Elastic Load Balancing load balancer to the layer's instances.
You can modify some Nginx configuration settings by using custom JSON or a custom attributes file. For more information, see Overriding Attributes. For a list of Apache attributes that can be overridden, see nginx Attributes.
Important
If your web application uses SSL, we recommend that you disable SSLv3 if possible
to address the vulnerabilities described in CVE-2014-3566
To disable SSLv3, you must modify the Nginx server's
nginx.conf
file. To do so, override the built-in nginx cookbook'snginx.conf.erb
template file, which the Rails App Server layer's Setup
recipes use to create nginx.conf
, and add the following
directive:
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
For more information on how to configure nginx.conf
, see
Configuring HTTPS servers