Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
LighthouseCIによるパフォーマンス測定/Performance measuremen...
Search
ワンキャリアTech
October 20, 2025
90
0
Share
LighthouseCIによるパフォーマンス測定/Performance measurement with LighthouseCI
SREチームの中岡が、ココナラ様・ソーシャルデータバンク様との合同勉強会にて登壇した際の資料となります。
ワンキャリアTech
October 20, 2025
More Decks by ワンキャリアTech
See All by ワンキャリアTech
AIがマネジメントを奪った今、 EMは何で価値を生むのか?/Now that AI has taken over management, how can Engineering Managers (EMs) create value?
onecareer_tech
0
40
AI時代だからこそ「思考の訓練」を徹底する/In this age of AI, we must thoroughly train our thinking skills.
onecareer_tech
0
52
「開発生産性」ではなく「事業生産性」こそが本質~ ROICで紐解く、開発の「稼ぐ力」の最大化 ~
onecareer_tech
8
3.7k
SREとプロダクトエンジニアは なぜ、分断されてしまうのか/Why are sre team and product teams so disconnected?
onecareer_tech
2
3.8k
Claude Code 全エンジニア導入にあたって行なった 権限管理、計測基盤構築、推進活動について / Regarding permission management, measurement infrastructure construction, and promotion activities for the implementation of Claude Code for all engineers
onecareer_tech
0
170
AI駆動で「実装の解像度」を上げる ~仕様駆動開発というアプローチ~ / Increasing "implementation resolution" through AI-driven development ~An approach called Specification-Driven Development~
onecareer_tech
0
180
Claude Code Actions を使った レビューの効率化/Streamlining reviews with Claude Code Actions
onecareer_tech
0
220
ワンキャリアにおけるEMの役割と育て方/The role and development of engineering managers at ONECAREER
onecareer_tech
0
32
SREとSWE、2つの視点から得た学び/Lessons learned from two perspectives: SRE and SWE
onecareer_tech
0
190
Featured
See All Featured
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
450
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
199
73k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
1.1k
How To Speak Unicorn (iThemes Webinar)
marktimemedia
1
460
30 Presentation Tips
portentint
PRO
1
300
The Limits of Empathy - UXLibs8
cassininazir
1
330
Exploring anti-patterns in Rails
aemeredith
3
360
Build The Right Thing And Hit Your Dates
maggiecrowley
39
3.1k
HDC tutorial
michielstock
2
670
AI Search: Where Are We & What Can We Do About It?
aleyda
0
7.5k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
360
30k
Transcript
LighthouseCIʹΑΔύϑΥʔϚϯεଌఆ 2025/09/29ɹגࣜձࣾϫϯΩϟϦΞ தԬ ໌
Career झຯ ͻͱ͜ͱ ONE CAREER Inc . ࣗݾհ Copyright ©
ONE CAREER Inc. All Rights Reserved. தԬ ໌ ॴଐձࣾɿSIer → SES → ࣄۀձࣾ ΩϟϦΞɿΠϯϑϥΤϯδχΞ → Ϛωʔδϟʔ → SRE(ࠓ) 2 εΩϡʔόμΠϏϯά SRE ຊΑΖ͓͘͠ئ͍͠·͢ʂ
࣍ Copyright © ONE CAREER Inc. All Rights Reserved. 3
• Core Web Vitalsʹ͍ͭͯ • LighthouseCIͷಋೖͷഎܠ • ಋೖʹΑΔ৽ͨͳ՝ • ղܾࡦͱ݁Ռ • ·ͱΊ
࣍ Copyright © ONE CAREER Inc. All Rights Reserved. 4
• Core Web Vitalsʹ͍ͭͯ • LighthouseCIͷಋೖͷഎܠ • ಋೖʹΑΔ৽ͨͳ՝ • ղܾࡦͱ݁Ռ • ·ͱΊ
Copyright © ONE CAREER Inc. All Rights Reserved. 5 Core
Web VitalsΛ͝ଘ͡Ͱ͔͢ʁ
Copyright © ONE CAREER Inc. All Rights Reserved. ࠷େίϯςϯπͷදࣔ࣌ؒ 2.5ඵҎ͕ཧ
ϢʔβʔΞΫγϣϯޙͷදࣔ 200ϛϦඵະຬ͕ཧ ૢ࡞࣌ͷදࣔζϨ߹͍ 0.1ະຬ͕ཧ Core Web Vitalsͱ 6 ϢʔβʔମݧʢUXʣΛΑΓྑ͘͢ΔͨΊGoogleͰఏএ͞ΕͨҎԼ3ͭͷࢦඪ ϫϯΩϟϦΞͰɺϢʔβʔମݧʹ݁͢ΔLCPΛɺSLOͷࢦඪͷͻͱͭͱͯ͠ܭଌ ը૾ࢀরݩɿhttps://www.debugbear.com/blog/hardest-core-web-vitals-metric
Copyright © ONE CAREER Inc. All Rights Reserved. ϫϯΩϟϦΞͰɺChromeͷ։ൃπʔϧʹଂ͞Ε͍ͯΔʮLighthouseʯΛ༻͍ͯଌఆ Core
Web VitalsΛଌఆ͢Δπʔϧ 7 LighthouseɿҎԼ5ͭͷࢦඪ͔Β Core Web Vitals ΛଌఆͰ͖ΔΦʔϓϯιʔεͷπʔϧ ɹ࠷େίϯςϯπͷදࣔ࣌ؒ ɹૢ࡞࣌ͷදࣔζϨ߹͍ ɹϢʔβʔૢ࡞ʹϖʔδ͕ԠͰ͖ͳ͍࣌ؒͷ߹ܭ ɹϒϥβ͕࠷ॳͷDOMίϯςϯπඳըʹ͔͔Δ࣌ؒ ɹϖʔδͷಡΈࠐΈதʹίϯςϯπ͕ࢹ֮తʹදࣔ͞ΕΔ࣌ؒ ɹLCPʢLargest Contentful Paintʣ ɹCLSʢCumulative Layout Shiftʣ ɹTBTʢTotal Blocking Timeʣ ɹFCPʢFirst Contentful Paintʣ ɹSI ʢSpeed Indexʣ ब׆αΠτʮϫϯΩϟϦΞʯͷ Topϖʔδॏཁը໘ͳͲΛରʹ ܭଌ
࣍ Copyright © ONE CAREER Inc. All Rights Reserved. 8
• Core Web Vitalsʹ͍ͭͯ • LighthouseCIͷಋೖͷഎܠ • ಋೖʹΑΔ৽ͨͳ՝ • ղܾࡦͱ݁Ռ • ·ͱΊ
Copyright © ONE CAREER Inc. All Rights Reserved. LighthouseͰଌఆ݁Ռ͕҆ఆͤͣɺLighthouseCIͷಋೖΛ࣮ࢪ LighthouseCIͷಋೖͷഎܠ
9 • ॳͷํ๏ɿChromeଂͷʮLighthouseʯͰखಈଌఆ • ໘ͨ͠՝ɿ݁Ռ͕҆ఆ͠ͳ͍ ◦ ଌఆ͢ΔPCͷੑೳωοτڥʹΑ͕ͬͯҟͳΓɺ݁ՌΛਖ਼֬ʹൺֱͰ͖ͳ͍ঢ়گʹ • ղܾࡦɿࣗಈԽπʔϧͷʮLighthouseCIʯΛಋೖ • తɿ͍ͭɾ୭͕ͬͯʮಉ͡ڥʯͰଌఆͰ͖ΔΑ͏ʹ͢Δ
Copyright © ONE CAREER Inc. All Rights Reserved. WebαΠτͷύϑΥʔϚϯεΛܧଓతʹࢹɾվળ͢ΔͨΊͷࣗಈԽπʔϧ LighthouseCIͱʁ
10 • Github ActionsͳͲͷCI/CDڥͰ࣮ߦ • ࣮ߦڥ͕ಉҰͳͷͰɺϒϨ͕ى͜Γʹ͍ͣ͘ • ࢀߟɿLighthouseCIͷϦϙδτϦ ◦ https://github.com/GoogleChrome/lighthouse-ci
Copyright © ONE CAREER Inc. All Rights Reserved. 11 ࢀߟɿLighthouseCIͷઃఆ
(Github Actionsͷ߹) name: Lighthouse CI on: workflow_dispatch: # खಈ࣮ߦ jobs: lighthouse: runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v5 - name: Setup Node.js uses: actions/setup-node@v5 with: node-version: '22' - name: Install dependencies run: | npm install -g @lhci/
[email protected]
- name: Run Lighthouse CI # ConfigϑΝΠϧͷఆٛʹै࣮ͬͯߦ run: lhci collect --config=.lighthouseci/lighthouserc.js env: LHCI_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Prepare artifacts if: always() run: | mkdir -p lighthouse-reports cp .lighthouseci/lhr-*.html lighthouse-reports/ || echo "No HTML files to copy" cp .lighthouseci/lhr-*.json lighthouse-reports/ || echo "No JSON files to copy" ls -la lighthouse-reports/ - name: Upload Lighthouse reports # ݁ՌΛGithub্͔ΒμϯϩʔυՄೳʹ͢Δ uses: actions/upload-artifact@v4 if: always() with: name: lhci-report path: lighthouse-reports/ retention-days: 30 “.github/workflows/lighthouse-ci.yml” ͱ͍͏ϑΝΠϧ໊Ͱ࡞
Copyright © ONE CAREER Inc. All Rights Reserved. ࢀߟɿLighthouseCIͷઃఆ (Github
Actionsͷ߹) 12 collect: { url: [ 'https://onecareer.jp/', // ଌఆ͍ͨ͠URL ], numberOfRuns: 3, // ࢼߦճ settings: { preset: 'desktop', formFactor: 'desktop', // σεΫτοϓڥΛ໌ࣔతʹࢦఆ onlyCategories: ['performance'], // ύϑΥʔϚϯεଌఆʹूத ConfigϑΝΠϧ: “lighthouserc.js“ ͱ͍͏ϑΝΠϧ໊Ͱهड़ʢҎԼɺઃఆ༰Λൈਮʣ
Copyright © ONE CAREER Inc. All Rights Reserved. ࢀߟɿLighthouseCIͷઃఆ (Github
Actionsͷ߹) 13 throttling: { rttMs: 10, // ϥϯυτϦοϓλΠϜ(ms) requestLatencyMs: 0, // ϦΫΤετϨΠςϯγ downloadThroughputKbps: 9000, // μϯϩʔυɿ9Mbps uploadThroughputKbps: 9000, // Ξοϓϩʔυɿ9Mbps cpuSlowdownMultiplier: 0.1 // CPUੑೳ10ഒԽʢM4 Pro/Max૬ʣ }, throttlingMethod: 'simulate', // ࣮ࡍͷ௨৴ߦΘͣܭࢉͰ༧ଌ } ConfigϑΝΠϧ: “lighthouserc.js“ ͱ͍͏ϑΝΠϧ໊Ͱهड़ʢҎԼɺઃఆ༰Λൈਮʣ
Copyright © ONE CAREER Inc. All Rights Reserved. 14 ͜ΕͰҰ؏ͨ͠ج४Ͱ
ൺֱͰ͖ΔΑ͏ʹͳͬͨ… ͣͩͬͨɻ
࣍ Copyright © ONE CAREER Inc. All Rights Reserved. 15
• Core Web Vitalsʹ͍ͭͯ • LighthouseCIͷಋೖͷഎܠ • ಋೖʹΑΔ৽ͨͳ՝ • ղܾࡦͱ݁Ռ • ·ͱΊ
Copyright © ONE CAREER Inc. All Rights Reserved. LighthouseCIͱखݩͷPCͷܭଌʹେ͖ͳ͕ࠩ... ಋೖʹΑΔ৽ͨͳ՝
16 • ৽ͨͳɿࣗಈπʔϧͱखݩͷPCͰɺ݁Ռʹେ͖ͳ͕ࠩੜ·Εͯ͠·ͬͨ ◦ ಛʹɺ ಡΈࠐΈʢLCPʣ͕ ࣮ࡍΑΓ͔ͳΓ͍Ͱࢉग़͞Εͯ͠·͏ ࣮ػʢMacBook pro M4ʣ+ Chrome LighthouseCI
Copyright © ONE CAREER Inc. All Rights Reserved. Lighthouseʹ͓͚Δܭଌํ๏ͷҧ͍ͷେ͖͕͞ɺ݁ՌͷࠩΛੜΜͰ͍ͨ ͳͥ͜ͷΑ͏ͳ݁ՌʹͳΔͷ͔ʁ
17 • LighthouseCIɿSimulateϞʔυ ◦ ཧܭࢉͰείΞΛࢉग़͢Δ ◦ WebϖʔδΛղੳ͠ɺઃఆͨ͠ύϥϝʔλͰֶతʹܭଌ͢Δ ▪ ࣮ࡍʹWebʹΞΫηε͍ͯ͠Δ݁ՌͰͳ͍ • ࣮ػɿDevToolsϞʔυ ◦ Chrome্ͰଳҬ੍ݶɺCPU༻ͷ੍ݶΛߦ্ͬͨͰɺ࣮ࡍͷΞΫηεΛߦ͏ ◦ Πϯλʔωοτڥੑೳʹґଘ͢Δ
࣍ Copyright © ONE CAREER Inc. All Rights Reserved. 18
• Core Web Vitalsʹ͍ͭͯ • LighthouseCIͷಋೖͷഎܠ • ಋೖʹΑΔ৽ͨͳ՝ • ղܾࡦͱ݁Ռ • ·ͱΊ
Copyright © ONE CAREER Inc. All Rights Reserved. LighthouseCIͷܭࢉ݅Λௐ͠ɺܭࢉ݁Ռ͕࣮ࡍͷڥͷʹۙ͘ͳΔΑ͏ʹνϡʔχϯά ղܾࡦ
19 είΞʹେ͖͘Өڹ͢ΔύϥϝʔλʢεϩοτϦϯάઃఆपΓʣ ߲ rttMS ʢϥϯυτϦοϓλΠϜʣ requestLatencyMs ʢϦΫΤετ։࢝ϨΠςϯγʣ ֓ཁ αʔόʔͱΫϥΠΞϯτؒͰɺ ύέοτ͕ԟ෮͢Δͷʹ͔͔Δ࣌ؒʢϛϦඵʣ ϒϥβ͕ϦΫΤετΛ։͔࢝ͯ͠Β ࣮ࡍʹωοτϫʔΫૹ৴͕࢝·Δ·ͰͷԆ ௐํ DevToolsϞʔυͰ140msʹઃఆ͞Ε͍ͯΔ͕ SimulateϞʔυͰಉ͡Λ͏ͱείΞ͕ஶ͘͠Լ → ࠷ऴతʹ10msʹௐɹɹ جຊతʹ0msͰͳ͍ͱஅ
Copyright © ONE CAREER Inc. All Rights Reserved. LighthouseCIͷܭࢉ݅Λௐ͠ɺܭࢉ݁Ռ͕࣮ࡍͷڥͷʹۙ͘ͳΔΑ͏ʹνϡʔχϯά ղܾࡦ
20 CPUॲཧೳྗઃఆ ߲ cpuSlowdownMultiplier CPU੍ݶഒʢεϩοτϦϯάʣ ֓ཁ ࣮ࡍͷCPUੑೳʹର͢Δ੍ݶഒ 1.0͕ඪ४ͰɺΛ্͛ΔͱʹɺΛԼ͛ΔͱߴʹͳΔ benchmarkindexͷΛݩʹഒΛܾఆ͢Δ ɾ͕2.0ɿCPUͷ͕͍ʢCPUΛʹͯ͠ܭࢉʣ ɾ͕0.1ɿCPUͷ͕࠷ʢCPUΛ10ഒʹͯ͠ܭࢉʣ ௐํ ࣮ߦ͢Δrunnerͷੑೳʹґଘ͢ΔͨΊɺCPUΛ࠷ʹͯ͠ܭଌ → Λ0.1ʢCPUੑೳΛ10ഒͱͯ͠ܭࢉ) ʹௐ
Copyright © ONE CAREER Inc. All Rights Reserved. ύϥϝʔλௐޙͷείΞൺֱ ݁Ռ
21 LighthouseCI ࣮ػʢMacBook pro M4ʣ+ Chrome • ௐલͱൺֱͯ͠ɺ࣮ػʹ͍ۙείΞ͕ग़ΔΑ͏ʹͳͬͨ • ͕ɺ࣮ػͱಉͷείΞʹͳΒͣ
࣍ Copyright © ONE CAREER Inc. All Rights Reserved. 22
• Core Web Vitalsʹ͍ͭͯ • LighthouseCIͷಋೖͷഎܠ • ಋೖʹΑΔ৽ͨͳ՝ • ղܾࡦͱ݁Ռ • ·ͱΊ
Copyright © ONE CAREER Inc. All Rights Reserved. LighthouseCIʹΑΔύϑΥʔϚϯεଌఆ ·ͱΊ
23 ͨͩ͠ܭࢉͱ࣮ଌͷࠩΛຒΊΔͨΊ CPUͳͲͷεϩοτϦϯάઃఆΛௐ͢Δ͜ͱ͕ॏཁ LighthouseCIɺڥʹґΒͣ CoreWebVital Λܭଌ͢Δ͜ͱ͕Ͱ͖Δ ଌఆํ๏ʹΑͬͯมΘΔͨΊɺͷઈରΑΓ ܧଓͯ͠ܭଌͨ͠ͷਪҠΛݟΔ͜ͱ͕େʂ