Back to Blog

Introducing Full Volume Support in Convox v3 Kubernetes Racks

Introduction

In our continuous effort to enhance Convox's v3 Kubernetes (k8s) Racks, we are thrilled to introduce full support for AWS EFS volumes. This new feature expands the capabilities of your Convox-managed applications, providing robust and scalable file storage solutions for improved data management and sharing across service replicas.

What are AWS EFS Volumes?

AWS EFS (Elastic File System) offers a highly scalable file storage solution within the AWS cloud ecosystem. It supports multiple EC2 instances accessing the same file system simultaneously, making it perfect for applications that require shared access to files. AWS EFS volumes bring the benefits of persistent storage with scalability and flexibility to your Kubernetes applications.

Enhancing Data Management with AWS EFS Volumes

Shared Service Volumes:With support for access modes like ReadWriteOnce (RWO), ReadOnlyMany (ROM), and ReadWriteMany (RWM), AWS EFS volumes can cater to a variety of use cases:

  • ReadWriteOnce (RWO): Single-instance write operations, ideal for scenarios where each instance requires dedicated write access to its own set of files.
  • ReadOnlyMany (ROM): Multiple-instance read operations, perfect for distributing read-only data like configuration files or static content across multiple instances.
  • ReadWriteMany (RWM): Multi-instance read/write operations, enabling collaborative data handling and shared file access among several instances. This is especially beneficial for applications that need concurrent read and write operations from multiple sources.

Configuring AWS EFS Volumes

To utilize AWS EFS volumes in your Convox Kubernetes applications, follow these steps:

Enable the EFS CSI Driver:

First, set the efs_csi_driver_enable parameter to true:

convox rack params set efs_csi_driver_enable=true -r rackName

Configure your services to use awsEfs for persistent storage and the volumes themselves in your convox.yml e.g.

environment:
  - PORT=3000
services:
  web:
    build: .
    port: 3000
    volumeOptions:
      - awsEfs:
          id: "efs-1"
          accessMode: ReadWriteMany
          mountPath: "/my/data/"
      - awsEfs:
          id: "efs-2"
          accessMode: ReadOnlyMany
          mountPath: "/my/read-only/data/"
      - emptyDir:
          id: "test-vol"
          mountPath: "/my/test/vol"

Best Practices and Use Cases

AWS EFS volumes are ideal for a variety of scenarios:

  • Shared Storage Among Multiple Instances: Facilitate seamless data sharing and synchronization across multiple instances of your application, ensuring all instances can access and update shared files in real-time.
  • Persistent Storage Across Pod Restarts: Maintain data persistence even when pods are restarted or rescheduled, ensuring critical data is not lost and applications can resume operations without data integrity issues.
  • Scalable and High-Availability Storage: Leverage AWS EFS's inherent scalability and high availability to handle growing data demands and ensure reliable access to files, minimizing downtime and maximizing performance.

Common use cases for AWS EFS volumes include:

  • Content Management Systems (CMS): Allow multiple editors to access and modify shared content simultaneously, with changes immediately visible across the platform.
  • Data Processing and Analytics: Enable distributed data processing tasks where multiple instances need concurrent read/write access to the same datasets.
  • Shared Configuration and Resources: Distribute shared configuration files, libraries, or other resources that need to be consistently available across all instances of an application.

Version Requirements

To leverage AWS EFS volumes, ensure your rack is updated to version 3.18.2 or later.

Note: you must be on at least version 3.17.0 to perform this update.

Updating Your Rack:

If you are on a version prior to 3.18.2, update your rack using:

convox rack update 3.18.2 -r rackName

For detailed instructions on updating your rack, refer to the Convox documentation on Updating a Rack.

Conclusion

The addition of AWS EFS volume support in Convox's Kubernetes platform further solidifies our dedication to providing powerful, flexible solutions for your containerized applications. By incorporating this feature, you can enhance your data storage capabilities, ensuring that your applications can efficiently manage and share persistent data across various instances and workloads. Embrace the scalability and resilience of AWS EFS to take your application's data management to the next level.

Let your team focus on what matters.