DevOps
Зачем
- CI - обеспечения процесса непрерывной интеграции
- Tests: unit, codestyle, functional, endtoend, integration
- CD - процесс доставки, развертывания
- Deployment
- Service Mesh
- Доступность, Отказоустойчивость, Надежность
- Производительность
- Auto Scaling
- Infrastructure-as-Code (IaC) automation
- Сквозная функциональность
- SRE
Паттерны
- Модель DevOps оценки компании
- TODO Антипаттерны
- MTA nginx
- Strategy Deployment (например blue-green deployment)
Сколько сервисов(BC) в одном контейнере
Each container should do one thing and do it well. A few reasons:
- There’s a good chance you’d have to scale APIs and front-ends differently than databases.
- Separate containers let you version and update versions in isolation.
- While you may use a container for the database locally, you may want to use a managed service for the database in production. You don’t want to ship your database engine with your app then.
- Running multiple processes will require a process manager (the container only starts one process), which adds complexity to container startup/shutdown.
Auto Scaling
- NGinx sample
- Limit
- CPU
- MEM
Naming Convention
- Namespace
- env
- Label - key\value
- key - alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between, max length 253
- value - max length 63
- Reserved prefixes
- kubernetes.io
- kubernetes.azure.com
- k8s.io
- примеры
- release : stable, release, canary
- kubernetes.io/os : debian, linux
- kubernetes.azure.com/cluster : cl1
- kubernetes.io/part-of : родительская ИС\сервис
- kubernetes.io/version : semver format
- [sec.
/tenant-id](https://www.helpnetsecurity.com/2021/05/26/kubernetes-security/) : tenant-uid
- Tenant-Type service-Name Service-Type Component-Name Component-Technology Stack-Name module
- Type service: категория ИС: LK, CRM, IDM
- Technology Stack: PHP, .NET, Python, NodeJS, Java
- Type Component - Tier: api, db, cache, frontend, backend
- db: mssql, mysql
- api:
- cache: redis, memcached
Технологии
- Infrastructure-as-Code
- Контейнеризация
- Load balancer
- Edge
- CD
- Spinnaker
- Distributed Tracing
- API Managment