Talks
Speakers
Events
Topics
Sign in
Home
Talks
Speakers
Events
Topics
Leaderboard
Use
Analytics
Sign in
Suggest modification to this talk
Title
Description
RailsConf 2018: Operating Rails in Kubernetes by Kir Shatrov Moving from operations powered by scripts like Capistrano to containers orchestrated by Kubernetes requires a shift in practices. We'll talk about things beyond "Getting started with Kubernetes" guides, and cover such aspects of operations as gradual deployments, capacity planning, job workers and their safety, and how cloud environments like Kubernetes drastically change how we solve them. This presentation is about the lessons we learned while migrating hundreds of Rails apps within the organization to Kubernetes.
Date
Summarized using AI?
If this talk's summary was generated by AI, please check this box. A "Summarized using AI" badge will be displayed in the summary tab to indicate that the summary was generated using AI.
Show "Summarized using AI" badge on summary page
Summary
Markdown supported
### Summary of 'Operating Rails in Kubernetes' by Kir Shatrov The presentation by Kir Shatrov at RailsConf 2018 discusses the transition of running Rails applications in Kubernetes, focusing on the techniques and insights gained while migrating hundreds of apps at Shopify. The talk provides a comprehensive overview of Kubernetes, particularly how it reshapes the deployment practices for Rails applications. #### Key Points Discussed: - **Introduction to Kubernetes**: - Kubernetes revolutionizes container scheduling, making resource allocation more dynamic and efficient compared to static server setups managed by scripts like Capistrano or Chef. - **Describing Architecture**: - Instead of manually controlling servers, Kubernetes utilizes YAML files to describe desired states and resources, promoting a more declarative approach to configuration management. - **Rails App Special Considerations**: - Rails applications often involve multiple processes and long-running jobs, necessitating mindful strategies for graceful termination and scaling. - **12-Factor App Methodology**: - Adopting principles like disposability, idempotency, and concurrency can optimize Rails app deployment in Kubernetes. For example, properly handling long-running background jobs minimizes disruptions during shutdowns or restarts. - **Asset Management**: - Efficient resource usage is crucial; assets should be pre-compiled and included in Docker images rather than generated on each server, reducing overhead. - **Database Migrations**: - Traditional coupling of code deployment and migrations can create fragile deployments. Shatrov suggests asynchronous migrations to decouple these processes, mitigating rollback complexities when migrations fail. - **Secret Management**: - With the introduction of Rails 5.2, encrypted credentials are suggested as a secure method for managing sensitive information, replacing the need for numerous environment variables. - **Migration Support Tools**: - To ease the developer experience, a bot was created to generate necessary YAML configurations for Kubernetes deployments, and a gem called `kubernetes deploy` was developed to provide visibility into deployment progress, akin to Capistrano's interface. - **Kubernetes as a Solution**: - Kubernetes abstracts away hardware specifics, allowing developers to focus on application-level concerns and streamline the process of deploying and managing Rails applications, thus standardizing operations significantly. #### Conclusions: - Kir emphasizes the benefits of moving to Kubernetes for Rails applications, advocating that this transition enhances efficiency, scalability, and resilience of deployments. - The adoption of cloud-native practices allows teams to concentrate on application development without being bogged down by infrastructure management. Shatrov's insights illustrate a significant shift in operational practices, showcasing a modernized approach to Rails app management in a containerized world.
Suggest modifications
Cancel