Link
Embed
Share
Beginning
This slide
Copy link URL
Copy link URL
Copy iframe embed code
Copy iframe embed code
Copy javascript embed code
Copy javascript embed code
Share
Tweet
Share
Tweet
Slide 1
Slide 1 text
©2020 Wantedly, Inc. Deploy Flow at Wantedly نͱڧ੍ FORCIA Meetup #1 ʙDevOps͍͔ͬͯnightʙ Mar 10, 2020 - Shimpei OTSUBO @potsbo
Slide 2
Slide 2 text
©2020 Wantedly, Inc. 4IJNQFJ0UTVCP!QPUTCP Developer Experience Squad Wantedly, Inc. Kubernetes Dev Tools CI / CD AuthN / Z Productivity Dvorak
Slide 3
Slide 3 text
©2020 Wantedly, Inc. લఏͱͳΔ Wantedly ͷڥ AWS ͕ϝΠϯ 40 Engineers 6 Infrastructure Engineers 5 Kubernetes Clusters 300 namespaces in total GCP ͕Ұ෦ ΦϯϓϨϛεҰͳ͍ 99% of services are on Kubernetes 60 deploys per weekday
Slide 4
Slide 4 text
©2020 Wantedly, Inc. implement configure ask / help Wantedly ͕ආ͚ΔΓํ App Engineers Products infrastructure Infra Engineers
Slide 5
Slide 5 text
©2020 Wantedly, Inc. App Engineers Infra Engineers implement Access through tools and APIs Products infrastructure Provide tools automate Wantedly ͷΓํ
Slide 6
Slide 6 text
©2020 Wantedly, Inc. App Engineers Infra Engineers implement Access through tools and APIs Products infrastructure Provide tools automate Wantedly ͷΓํ Infra engineer ͱ App engineer ͕ૄ݁߹
Slide 7
Slide 7 text
©2020 Wantedly, Inc. ڧ੍Ͱ͖ΔΈΛߏங͢Δ •CI ͱϩʔΧϧͰಉҰͷπʔϧΛ͏ نͰੜ࢈ੑΛҡ࣋͢Δ •commit hash Λ tag ʹ͢Δ •ࣗಈ deploy •The Twelve Factors ʹଇΔ Ͳ͏Δ͔ •Interface ͷΈΛकΓཪυϥεςΟοΫʹม͍͑ͯ͘
Slide 8
Slide 8 text
©2020 Wantedly, Inc. ن same third-party services across all services commit hash Λ image tag PR merge Ͱࣗಈ deploy build/deploy monitoring etc… ಉҰͷ docker image ΛશڥͰ͏
Slide 9
Slide 9 text
©2020 Wantedly, Inc. The Latest k8s ops flow set image check pull deploy push push hook build build
Slide 10
Slide 10 text
©2020 Wantedly, Inc. 1 commit ʹରͯ͠ 1 docker image GitHub commit status Ͱ image ͷ࡞ঢ়گΛ feedback ΄΅ͯ͢ͷ commit ͕ deploy Մೳ push push hook build build The Latest k8s ops flow
Slide 11
Slide 11 text
©2020 Wantedly, Inc. `kube prod deploy master` Ͱ deploy `kubectl set image` Λ wrap ͍ͯ͠Δ શڥͰಉҰͷ image Λ͍ڥม͚͕ͩࠩ set image check pull deploy The Latest k8s ops flow ࣗಈͰ deploy ͞ΕΔ
Slide 12
Slide 12 text
©2020 Wantedly, Inc. نͰੜ࢈ੑΛҡ࣋͢Δ •commit hash Λ tag ʹ͢Δ •ࣗಈ deploy •The Twelve Factors ʹଇΔ
Slide 13
Slide 13 text
©2020 Wantedly, Inc. ඞཁͳͷ͕ͯ͢ἧ͏ࣾϥΠϒϥϦ servicex • Log format ͱૹ৴ • Error ऩू • ύϑΥʔϚϯεϞχλϦϯά • ࢄτϨʔγϯά • ଞͷαʔϏε Golang, Ruby, Python, Node Λαϙʔτ ڧ੍Ͱ͖ΔΈΛߏங͢Δ ϧʔϧΛकΔͷ͕Ұ൪؆୯Ͱ͋ΔੈքΛҡ࣋͢Δ
Slide 14
Slide 14 text
©2020 Wantedly, Inc. ڧ੍Ͱ͖ΔΈΛߏங͢Δ ͯ͢ͷ ops ͕ kube ίϚϯυͰՄೳ ϧʔϧΛकΔͷ͕Ұ൪؆୯Ͱ͋ΔੈքΛҡ࣋͢Δ ࣾπʔϧͰ build / deploy / ops ͷͯ͢ͷ࡞ۀ͕Մೳ CI Ͱ laptops Ͱಉ͡ͷΛ͏ ͲΜͳࣗಈԽ͕ߦΘΕ͍ͯΔͷ͔Θ͔Γ͍͢ kube build kube prod deploy master Ͱ docker image Λ build ͯ͠ push Ͱ production deploy Ͱੜ manifests ࣗಈੜ kube generate autoscale
Slide 15
Slide 15 text
©2020 Wantedly, Inc. language: bash env: - // encrypted credentials here install: - bash <(curl -sL https://get.wantedlyapp.com/kube) script: - kube build deploy: - skip_cleanup: true provider: script script: kube prod deploy $TRAVIS_COMMIT on: branch: master Travis ͷઃఆͷྫ
Slide 16
Slide 16 text
©2020 Wantedly, Inc. language: bash env: - // encrypted credentials here install: - bash <(curl -sL https://get.wantedlyapp.com/kube) script: - kube build deploy: - skip_cleanup: true provider: script script: kube prod deploy $TRAVIS_COMMIT on: branch: master Install kube Travis ͷઃఆͷྫ
Slide 17
Slide 17 text
©2020 Wantedly, Inc. language: bash env: - // encrypted credentials here install: - bash <(curl -sL https://get.wantedlyapp.com/kube) script: - kube build deploy: - skip_cleanup: true provider: script script: kube prod deploy $TRAVIS_COMMIT on: branch: master Install kube build and push a docker image Travis ͷઃఆͷྫ
Slide 18
Slide 18 text
©2020 Wantedly, Inc. language: bash env: - // encrypted credentials here install: - bash <(curl -sL https://get.wantedlyapp.com/kube) script: - kube build deploy: - skip_cleanup: true provider: script script: kube prod deploy $TRAVIS_COMMIT on: branch: master deploy the revision Install kube build and push a docker image Travis ͷઃఆͷྫ
Slide 19
Slide 19 text
©2020 Wantedly, Inc. Travis ͷઃఆͷྫ language: bash env: - // encrypted credentials here install: - bash <(curl -sL https://get.wantedlyapp.com/kube) script: - kube build deploy: - skip_cleanup: true provider: script script: kube prod deploy $TRAVIS_COMMIT on: branch: master deploy the revision Install kube build and push a docker image Interface ͑͞ม͑ͳ͚Ε৽͍͠มߋΛ؆୯ʹΒ·͚Δ ࣾඪ४ͷπʔϧΛ͏ͷ͕Ұ൪ָͩ͠উखʹྑ͘ͳΔ Infra Engineers App Engineers
Slide 20
Slide 20 text
©2020 Wantedly, Inc. ڧ੍Ͱ͖ΔΈΛߏங͢Δ •CI ͱϩʔΧϧͰಉҰͷπʔϧΛ͏ نͰੜ࢈ੑΛҡ࣋͢Δ •commit hash Λ tag ʹ͢Δ •ࣗಈ deploy •The Twelve Factors ʹଇΔ Ͳ͏Δ͔ •Interface ͷΈΛकΓཪυϥεςΟοΫʹม͍͑ͯ͘