This Guidance helps customers simplify the deployment of an ETH2 validator on Rocket Pool, powered by AWS Graviton-based instances. Rocket Pool is one of many decentralized staking pools that supports the Ethereum beacon chain. Validators who wish to earn rewards for staking may use Rocket Pool to create their own validation nodes. This Guidance uses AWS Cloud Development Kit (AWS CDK) and AWS Graviton-based instances to deploy ETH2 validators on the AWS Cloud with minimal setup time.

Architecture Diagram

[Architecture diagram description]

Download the architecture diagram PDF 

Well-Architected Pillars

The AWS Well-Architected Framework helps you understand the pros and cons of the decisions you make when building systems in the cloud. The six pillars of the Framework allow you to learn architectural best practices for designing and operating reliable, secure, efficient, cost-effective, and sustainable systems. Using the AWS Well-Architected Tool, available at no charge in the AWS Management Console, you can review your workloads against these best practices by answering a set of questions for each pillar.

The architecture diagram above is an example of a Solution created with Well-Architected best practices in mind. To be fully Well-Architected, you should follow as many Well-Architected best practices as possible.

  • In this architecture, we use infrastructure as code (IaC) to deploy AWS resources in a reliable and repeatable way. AWS CDK is a key aspect of achieving IaC in this Guidance. AWS CDK is an open-source software development framework that enables the creation and deployment of AWS resources using familiar programming languages such as TypeScript, Python, and Java. It allows developers to define cloud infrastructure in code, which can then be versioned, reviewed, and tested like any other software code.

    Using AWS CDK to deploy AWS resources provides several technical benefits, including repeatability and consistency, higher-level abstraction, code reuse, and support for standard software development practices. These benefits can help improve the reliability and efficiency of the deployment process, reducing the risk of errors and improving the overall quality of the AWS resources.

    Read the Operational Excellence whitepaper 
  • This architecture uses Systems Manager to access resources instead of using secure shell (SSH) access (which can be a security risk if not properly managed). To minimize the attack surface, no ports are open. Systems Manager enables secure remote management of instances, making it easier to manage instances across multiple accounts and AWS Regions. In addition to Systems Manager, this architecture uses AWS Identity and Access Management (IAM) to manage user access to resources. With Systems Manager and IAM, only authorized users will have access to AWS resources, reducing the risk of unauthorized access and data breaches. Systems Manager and IAM also provide audit trails and monitoring capabilities, enabling you to track user activity and identify any potential security issues. 

    Read the Security whitepaper 
  • This is a loosely-coupled microservices architecture, where everything runs as a Docker container. A loosely coupled microservices architecture provides several benefits for building a reliable system, including increased flexibility and agility, better fault isolation, improved resource utilization, and enhanced testing and debugging capabilities. 

    Additionally, using Prometheus and Grafana as a containerized monitoring stack supports log collection and metrics visualization. Prometheus is an open-source monitoring system that collects and stores time-series data from various sources, including applications and systems. Grafana is a visualization tool that provides a powerful and user-friendly dashboard for displaying metrics and logs collected by Prometheus. The combination of Prometheus and Grafana provides a powerful and comprehensive monitoring solution for AWS resources. The ability to collect and store time-series data and visualize it in an application and user-friendly dashboard enables easy monitoring and troubleshooting of this Guidance, improving the reliability and performance of the AWS resources and reducing the risk of downtime or performance issues to adjacent systems. 

    Read the Reliability whitepaper 
  • Scaling, traffic patterns, and data access patterns are important considerations when designing a blockchain node architecture, as they can have a significant impact on the performance and reliability of the node.

    Scaling is the ability of the blockchain node to handle increasing numbers of transactions and users. With this Guidance, a single AWS CDK command can increase the number of nodes in the network, which helps distribute the load and improve performance. 

    Traffic patterns are types of requests and data that are sent and received by the blockchain node. Data access patterns are how data is accessed and queried from the blockchain database. Understanding traffic patterns and data access patterns can help you optimize the performance of the node, allocate resources appropriately, and improve the user experience. The Prometheus and Grafana containers can help with monitoring and visualizing these metrics.

    Read the Performance Efficiency whitepaper 
  • We use a c6g.2xlarge AWS Graviton-based instance based on Rocket Pool's current recommendation. This is the optimized instance for this blockchain deployment. After the node validator is deployed, we recommend using AWS Cost Explorer to evaluate the cost of the c6g.2xlarge instance over time and to identify any potential savings opportunities. Additionally, we recommend using Amazon EC2 Reserved Instances (RIs), which can provide a discount of up to 72% compared to on-demand pricing. By continuously evaluating the cost of the selected instance type and identifying opportunities to optimize, you can use the most cost-effective services without compromising on performance or reliability. 

    This is a single node architecture. Blockchain nodes are highly decentralized, meaning you can spin up new nodes with single AWS CDK command. In this architecture, you do not need automatic scaling mechanisms to save on costs. 

    Read the Cost Optimization whitepaper 
  • In this Guidance, we prioritize energy efficiency, reduce hardware requirements, and minimize the carbon footprint of running the node. We run the validator node on AWS Graviton-based instances, which use a lower energy footprint and cost less. The validator node in this Guidance uses a lightweight Ethereum client (Geth), which consumes fewer resources than a full node.

    The validator node stores data on a solid-state drive (SSD) rather than a traditional hard disk drive (HDD), because SSDs are energy-efficient and have a longer lifespan. By adopting a minimalistic architecture, the Ethereum node validator in this Guidance can significantly reduce its energy consumption and carbon footprint, contributing to a more sustainable blockchain network.

    Read the Sustainability whitepaper 

Implementation Resources

A detailed guide is provided to experiment and use within your AWS account. Each stage of building the Guidance, including deployment, usage, and cleanup, is examined to prepare it for deployment.

The sample code is a starting point. It is industry validated, prescriptive but not definitive, and a peek under the hood to help you begin. 

AWS Database
Blog

Automate Ethereum node validator deployment on Amazon EC2 using AWS CDK

This post demonstrates how an AWS Cloud Development Kit (AWS CDK) app simplifies the deployment of Rocket Pool on Amazon EC2. 

Disclaimer

The sample code; software libraries; command line tools; proofs of concept; templates; or other related technology (including any of the foregoing that are provided by our personnel) is provided to you as AWS Content under the AWS Customer Agreement, or the relevant written agreement between you and AWS (whichever applies). You should not use this AWS Content in your production accounts, or on production or other critical data. You are responsible for testing, securing, and optimizing the AWS Content, such as sample code, as appropriate for production grade use based on your specific quality control practices and standards. Deploying AWS Content may incur AWS charges for creating or using AWS chargeable resources, such as running Amazon EC2 instances or using Amazon S3 storage.

References to third-party services or organizations in this Guidance do not imply an endorsement, sponsorship, or affiliation between Amazon or AWS and the third party. Guidance from AWS is a technical starting point, and you can customize your integration with third-party services when you deploy the architecture.

Was this page helpful?