自旋基础设施的冒险。容器、Systemd和CG组

The Spin infrastructure team works hard at improving the stability of the system. In February 2022 we moved to Container Optimized OS (COS), the Google maintained operating system for their Kubernetes Engine SaaS offering. A month later we turned on multi-cluster to allow for increased scalability as more users came on board. Recently, we’ve increased default resources allotted to instances dramatically. However, with all these changes we’re still experiencing some issues, and for one of those, I wanted to dive a bit deeper in a post to share with you.

Spin基础设施团队努力提高系统的稳定性。2022年2月,我们转移到容器优化操作系统(COS),这是谷歌为其Kubernetes引擎SaaS产品维护的操作系统。一个月后,我们开启了多集群,以便随着更多用户的加入,提高可扩展性。最近,我们大幅增加了分配给实例的默认资源。然而,随着所有这些变化,我们仍然遇到了一些问题,对于其中的一个问题,我想在一篇文章中深入探讨一下,与大家分享。

Spin’s Basic Building Blocks

旋转的基本构件

First it's important to know the basic building blocks of Spin and how these systems interact. The Spin infrastructure is built on top of Kubernetes, using many of the same components that Shopify’s production applications use. Spin instances themselves are implemented via a custom resource controller that we install on the system during creation. Among other things, the controller transforms the Instance custom resource into a pod that’s booted from a special Isospin container image along with the configuration supplied during instance creation. Inside the container we utilize systemd as a process manager and workflow engine to initialize the environment, including installing dotfiles, pulling application source code, and running through bootstrap scripts. Systemd is vital because it enables a structured way to manage system initialization and this is used heavily by Spin.

首先,了解Spin的基本构件以及这些系统如何互动是很重要的。Spin基础设施建立在Kubernetes之上,使用Shopify的生产应用所使用的许多相同组件。Spin实例本身是通过我们在创建期间安装在系统上的自定义资源控制器实现的。在其他方面,该控制器将Instance 自定义资源转化为一个pod,该pod从一个特殊的Isospin 容器镜像中启动,并在实例创建期间提供配置。在容器内,我们利用systemd作为进程管理器和工作流引擎来初始化环境,包括安装dotfiles,提取应用源代码,并通过引导脚本运行。systemd至关重要,因为它能以结构化的方式来管理系统初始化,这一点被Spin大量使用。

There’s definitely more to what makes Spin then what I’ve described, but ...

开通本站会员,查看完整译文。

trang chủ - Wiki
Copyright © 2011-2024 iteam. Current version is 2.137.3. UTC+08:00, 2024-11-28 18:51
浙ICP备14020137号-1 $bản đồ khách truy cập$