Slide 1

Slide 1 text

당근 개발자 플랫폼은 어떤 문제를 해결하고 있는가? 사진: Unsplash의 Michael C 2024.1.10 @ AWSKRUG 플랫폼엔지니어링모임 Outsider

Slide 2

Slide 2 text

당근마켓 SRE Outsider’s Dev Story 블로그 44BITS 팟캐스트 RetroTech 팟캐스트 Outsider

Slide 3

Slide 3 text

Kubernetes

Slide 4

Slide 4 text

Platform Engineering이 목표는 아니다

Slide 5

Slide 5 text

데모 영상입니다. 데모는 YouTube에서 볼 수 있습니다. 3분 정도 됩니다.

Slide 6

Slide 6 text

데모 데모는 YouTube에서 3분

Slide 7

Slide 7 text

2021년 SRE팀 딜리버리 파트 저는 2020년 12월 입사

Slide 8

Slide 8 text

Argo CD Kustomize +

Slide 9

Slide 9 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action

Slide 10

Slide 10 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action AWS ECR Push Image

Slide 11

Slide 11 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action AWS ECR g Repo for Argo CD Push Image Update image tag

Slide 12

Slide 12 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action AWS ECR g Repo for Argo CD Argo CD Push Image Update image tag Out of Sync

Slide 13

Slide 13 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action AWS ECR g Repo for Argo CD Argo CD Kubernetes Cluster Push Image Update image tag Sync Out of Sync

Slide 14

Slide 14 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action AWS ECR g Repo for Argo CD Argo CD Kubernetes Cluster Push Image Update image tag Sync Out of Sync AWS Parameter Store

Slide 15

Slide 15 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action AWS ECR g Repo for Argo CD Argo CD Kubernetes Cluster Push Image Update image tag Sync Out of Sync AWS Parameter Store SRE: ୡӝ ࢸ੿

Slide 16

Slide 16 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action AWS ECR g Repo for Argo CD Argo CD Kubernetes Cluster Push Image Update image tag Sync Out of Sync AWS Parameter Store SRE: ୡӝ ࢸ੿ SRE: ࢲ࠺झ য஠਍౟ ࢸ੿/IAM সؘ੉౟

Slide 17

Slide 17 text

파편화 Fragmentation 사진: Unsplash의 Kelly Sikkema

Slide 18

Slide 18 text

파편화 Fragmentation 사진: Unsplash의 Kelly Sikkema 50+

Slide 19

Slide 19 text

g Repo for Argo CD ࢎղ ূ૑פয SRE

Slide 20

Slide 20 text

Separation of Concerns 사진: Unsplash의 Alex Padurariu

Slide 21

Slide 21 text

수정하기 어렵다

Slide 22

Slide 22 text

반복되는 배포 요청

Slide 23

Slide 23 text

YAML 사진: Unsplash의 Alexander Simonsen YAML YAML YAML YAML YAML

Slide 24

Slide 24 text

고쳐쓸까? 새로 만들까?

Slide 25

Slide 25 text

Argo CD를 버린다

Slide 26

Slide 26 text

Argo CD를 버린다 ࢜ ߓನदझమ਷ ࢜۽ ҳ୷೤פ׮

Slide 27

Slide 27 text

좋은 배포란 무엇인가?

Slide 28

Slide 28 text

누가 언제 무엇을 배포했는가?

Slide 29

Slide 29 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action g Repo for Argo CD Argo CD Kubernetes Cluster Sync

Slide 30

Slide 30 text

No content

Slide 31

Slide 31 text

No content

Slide 32

Slide 32 text

No content

Slide 33

Slide 33 text

누가 언제 무엇을 배포했는가? ־ҳٚ औѱ ঌ ࣻ ੓যঠ

Slide 34

Slide 34 text

상태 동기화 최종 일관성 desired state = actual state Eventually Consistency

Slide 35

Slide 35 text

v1 운영 중

Slide 36

Slide 36 text

v1 운영 중 v2로 변경 제출 v1

Slide 37

Slide 37 text

v1 운영 중 v2로 변경 제출 desired state 동기화 v1

Slide 38

Slide 38 text

v1 운영 중 v2로 변경 제출 desired state 동기화 v1 v2 rollout 완료

Slide 39

Slide 39 text

v1 운영 중 v2로 변경 제출 desired state 동기화 v1 v2 rollout 완료 Argo CD의 동기화 완료

Slide 40

Slide 40 text

v1 운영 중 v2로 변경 제출 desired state 동기화 v1 v2 rollout 완료 Argo CD의 배포 완료 엔지니어가 기대하는 배포 완료

Slide 41

Slide 41 text

Kubernetes를 몰라도 배포할 수 있어야 한다 Kubernetes를 알면 더 잘 쓸수 있다

Slide 42

Slide 42 text

오늘 입사한 사람도 배포할 수 있어야 한다

Slide 43

Slide 43 text

처음부터 끝까지 직접 할 수 있어야 한다 Self-Service

Slide 44

Slide 44 text

사진: Unsplash의 Bernd Klutsch 문서 없이도 사용할 수 있을 정도로 편해야 한다

Slide 45

Slide 45 text

설문 조사는 하지 않습니다 사진: Unsplash의 Celpax

Slide 46

Slide 46 text

사람들은 원인이 아니라 해쳘책을 가져온다 사진: Unsplash의 SIMON LEE

Slide 47

Slide 47 text

Opinionated

Slide 48

Slide 48 text

단순함 유연함

Slide 49

Slide 49 text

Convention over Configuration

Slide 50

Slide 50 text

90%

Slide 51

Slide 51 text

Kubernetes manifest 추상화

Slide 52

Slide 52 text

Configuration files

Slide 53

Slide 53 text

No content

Slide 54

Slide 54 text

어디서부터 배포라고 할 것인가?

Slide 55

Slide 55 text

௏٬ పझ౟ Docker ࠽٘ Docker ಹद Kubernetes manifest kubectl apply

Slide 56

Slide 56 text

g c Repo GitHub Action g c Repo GitHub Action g c Repo GitHub Action AWS ECR g Repo for Argo CD Push Image Update image tag

Slide 57

Slide 57 text

௏٬ పझ౟ Docker ࠽٘ Docker ಹद Kubernetes manifest kubectl apply GitHub Argo CD

Slide 58

Slide 58 text

௏٬ పझ౟ Docker ࠽٘ Docker ಹद Kubernetes manifest kubectl apply GitHub 새 배포 시스템

Slide 59

Slide 59 text

Deployment Backend CLI

Slide 60

Slide 60 text

No content

Slide 61

Slide 61 text

No content

Slide 62

Slide 62 text

GoCD CLI UI

Slide 63

Slide 63 text

Mockup

Slide 64

Slide 64 text

No content

Slide 65

Slide 65 text

No content

Slide 66

Slide 66 text

No content

Slide 67

Slide 67 text

No content

Slide 68

Slide 68 text

https://primer.style/

Slide 69

Slide 69 text

https://github.blog/2021-01-25-improving-how-we-deploy-github/

Slide 70

Slide 70 text

MVP

Slide 71

Slide 71 text

type: v1/appservice services: app: image: app ports: - name: http port: 8080 healthcheck: type: http httpPath: /api/healthy port: 8080 interval: 10 startPeriod: 30 images: app: dockerfile: ./Dockerfile routes: - name: http protocol: http host: - scope: internal backend: - service: app port: http

Slide 72

Slide 72 text

No content

Slide 73

Slide 73 text

No content

Slide 74

Slide 74 text

No content

Slide 75

Slide 75 text

No content

Slide 76

Slide 76 text

IRSA, IAM

Slide 77

Slide 77 text

{ "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:ListBucket" ], "Resource": [ "arn:aws:s3 ::: test-service-bucket", "arn:aws:s3 ::: test-service-bucket /* " ] } ] } type: v1/appservice services: app: role: app-role roles: app-role: .deploy/policies/app.json

Slide 78

Slide 78 text

No content

Slide 79

Slide 79 text

마이그레이션은 힘들다

Slide 80

Slide 80 text

Kontrol을 더 좋게 만든다 사진: Unsplash의 Miguel Bruna

Slide 81

Slide 81 text

배포 후 상태를 보고 싶다

Slide 82

Slide 82 text

No content

Slide 83

Slide 83 text

No content

Slide 84

Slide 84 text

No content

Slide 85

Slide 85 text

파편화된 환경 변수

Slide 86

Slide 86 text

Configmap External Secrets AWS Parameter Store g Repo for Argo CD

Slide 87

Slide 87 text

No content

Slide 88

Slide 88 text

No content

Slide 89

Slide 89 text

No content

Slide 90

Slide 90 text

https://netflixtechblog.com/full-cycle- developers-at-netflix-a08c31f83249

Slide 91

Slide 91 text

https://netflixtechblog.com/full-cycle- developers-at-netflix-a08c31f83249

Slide 92

Slide 92 text

“ ” SRE란 운영팀을 위한 소프트웨어 엔지니어를 말한다. https://sre.google/sre-book/table-of-contents/

Slide 93

Slide 93 text

“ ” 기본적으로 SRE팀은 엔지니어링에 초점을 맞춘다는 점이 가장 중요하다. 끊임없이 엔지니어링을 추구하지 않으면 업무 부담이 증가하여 그 부담을 나누기 위해 더 많은 인력이 필요하게 되고 결국에는 서비스의 크기에 따라 전통적인 운영 업무를 담당하는 인력이 기하급수적으로 늘어나게 된다. https://sre.google/sre-book/table-of-contents/

Slide 94

Slide 94 text

“ ” 이러한 숙명에서 벗어나려면 서비스를 관리하는 팀은 코드를 작성해야 한다. 그렇지 못하면 늘어나는 일감에 파묻히게 될 뿐이다. 그래서 구글은 SRE팀에 티켓, 전화 응대, 수작업 등, 소위 '운영' 업무에 최대 50%의 시간만 투입하도록 정해두고 있다. https://sre.google/sre-book/table-of-contents/

Slide 95

Slide 95 text

프로젝트 소유권 관리

Slide 96

Slide 96 text

No content

Slide 97

Slide 97 text

No content

Slide 98

Slide 98 text

No content

Slide 99

Slide 99 text

No content

Slide 100

Slide 100 text

사진: Unsplash의 Filip Bunkens IT 겨울

Slide 101

Slide 101 text

비용의 가시성을 높여야 한다

Slide 102

Slide 102 text

No content

Slide 103

Slide 103 text

사용성이 좋지 않은 Kubernetes 크론잡

Slide 104

Slide 104 text

No content

Slide 105

Slide 105 text

No content

Slide 106

Slide 106 text

No content

Slide 107

Slide 107 text

운영의 사용성 개선

Slide 108

Slide 108 text

No content

Slide 109

Slide 109 text

No content

Slide 110

Slide 110 text

클라우드 리소스의 소유권을 관리할 수 있으니 생성도 하고 싶다

Slide 111

Slide 111 text

No content

Slide 112

Slide 112 text

No content

Slide 113

Slide 113 text

EOF g outsideris t outsideris e [email protected]