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
How GitHub uses Codespaces
Search
Yuichi Tanaka
August 31, 2022
Programming
1.3k
3
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
How GitHub uses Codespaces
Tech Stand #9 GitHubにてお話しした際の資料です。
https://standfm.connpass.com/event/256786/
Yuichi Tanaka
August 31, 2022
More Decks by Yuichi Tanaka
See All by Yuichi Tanaka
GitHub Copilot Tips and Tricks (en)
yuichielectric
1
340
GitHub Copilot Tips and Tricks
yuichielectric
43
20k
30分でわかるシステム運用アンチパターン / Operations Anti Patterns in 30 minutes
yuichielectric
14
21k
オープンソースのベストプラクティスを企業内で実践/How to implement InnerSource
yuichielectric
12
19k
GitHubにおける継続的デリバリー/How GitHub builds and deploy software
yuichielectric
12
4.5k
GitHubにおける GitHub Actions利用法/How GitHub uses GitHub Actions
yuichielectric
7
820
InnerSourceのすすめ / InnerSource
yuichielectric
8
2k
GitHub Pro Tips
yuichielectric
0
260
Other Decks in Programming
See All in Programming
Observability in Practice:Grafana 與 Edge Device SRE 的那些事
blueswen
0
180
[2026年度第1回ORセミナー] 計画最適化ベンチャーと競技プログラミング人材
terryu16
0
270
TSKaigi Night Talks 2026_TypeScriptでサプライチェーンの整合性を型に閉じ込める
geekplus_tech
0
410
A2UI という光を覗いてみる
satohjohn
1
160
Spring Security 実践 ─ GraphQL APIで実務に役立つ 認証・認可 を学ぶ
wagyu
0
260
Vue × Nuxt × Oxc どこまで使える?実運用の現在地
andpad
0
300
不変条件と整合性境界—ビジネスが決める設計判断と実現パターン / Invariants and Consistency Boundaries
nrslib
14
5.8k
LLM本来の能力を解き放つサンドボックス技術とAI民主化への適用
yukukotani
3
4.5k
気づいたらRubyで100作品 ー クリエイティブコーディングが生活の一部になるまで / 100 Ruby Sketches Later: How Creative Coding Became Part of My Life
chobishiba
3
610
AI時代のUIはどこへ行く?その2!
yusukebe
22
7.5k
LLMによるContent Moderationの本番運用の裏側と品質担保への挑戦
suikabar
3
780
スマートグラスで並列バイブコーディング
hyshu
0
260
Featured
See All Featured
It's Worth the Effort
3n
188
29k
How GitHub (no longer) Works
holman
316
150k
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
540
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.3k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
34
2.8k
HTML-Aware ERB: The Path to Reactive Rendering @ RubyCon 2026, Rimini, Italy
marcoroth
2
250
Odyssey Design
rkendrick25
PRO
2
710
Bash Introduction
62gerente
615
220k
Rebuilding a faster, lazier Slack
samanthasiow
85
9.5k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
240
Speed Design
sergeychernyshev
33
1.9k
Un-Boring Meetings
codingconduct
0
320
Transcript
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric 田中
裕一 (@yuichielectric) How GitHub uses Codespaces
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric 田中
裕一 GitHub、シニアソリューションズエンジニア 個人で「システム運用アンチパターン」 (オライリー・ジャパン)の翻訳を担当 @yuichielectric
Codespaces クラウド上の開発環境 妥協のないコーディング体験 ブラウザから、コーディング、ビルド、テスト、 デバッグ、デプロイが可能な完全な開発環境に アクセス。 ワークフローをシンプルに 依存関係やSSHキーを自動でセットアップ。 あらゆるプロジェクトでコーディングを開始できる までの時間を短縮。
カスタマイズ可能 dotfileによるエディタの設定やすべてのCodespace 環境にあらかじめインストールしておくVS Code拡 張の指定など
{ "name": "Go", "build": { "dockerfile": "Dockerfile", "args": { "VARIANT":
"1-bullseye", } }, "runArgs": [ "--cap-add=SYS_PTRACE", "--security-opt", "seccomp=unconfined" ], "settings": { "go.toolsManagement.checkForUpdates": "local", "go.useLanguageServer": true, "go.gopath": "/go", "go.goroot": "/usr/local/go" }, "extensions": [ "golang.Go" ], "forwardPorts": [8080], "postCreateCommand": "go version", "remoteUser": "vscode" } https://github.com/microsoft/vscode-dev-containers/blob/main/containers/go/.devcontainer/devcontainer.json 名前 コンテナの指定 Visual Studio Codeの設定 Visual Studio Code拡張 フォワードするポート 環境作成後コマンド 実行ユーザー コンテナ実行時パラメータ .devcontainer/devcontainer.json
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric GitHub社内での標準の開発環境
github/github: コミット数100万以上、サイズは 13GB以上 Codespaces以前 各エンジニアのmac上に開発環境を 構築。すべてスクリプト化されては いたものの、環境構築には半日 かかっていた。 Codespaces以後 github/githubの環境を10秒で用意 ブランチ切り替えの必要なし VS Codeユーザー以外からもSSH https://github.blog/jp/2021-08-30-githubs-engineering-team-moved-codespaces/
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric コンテナイメージ
ベースイメージ用のリポジトリを作 り、Actionsで、イメージをビルド しPackagesにpush プリビルド github/githubのmainへのマージ のたびにCodespaces環境をビルド 環境 32コア、64GBメモリのマシン サイズのみを使うように設定 https://docs.github.com/ja/codespaces/prebuilding-your-codespaces/about-github-codespaces-prebuilds Codespace環境のビルド
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric Codespaceのビルド(プリビルドも
含む)は複数リポジトリにも対応 関連するリポジトリに対しての 権限を要求した上で、プリビルド 環境を構築後に必要なリポジトリ を取得してセットアップ https://github.blog/changelog/2022-07-28-prebuilding-codespaces-is-now-supported-for-multi-repository-and-monorepo-projects/ 複数リポジトリ
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric VPNのセットアップをfeaturesを使って共通化。
プロジェクトごとに必要に応じて利用。 その他の手段として、ローカルマシンを、Codespaceと プライベートリソースへのゲートウェイとして使うことも可能。 GitHub CLI拡張としてプレビュー公開。 https://github.com/github/gh-net プライベートリソースへのアクセス
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric Codespaces環境に単機能を追加するプロセスを定義するための仕組み
例 • GitHub CLI • Ruby • SSHサーバ 独自のfeatureを定義することも可能。 devcontainers/feature-template features
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric Codespacesの別の側面
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric ドキュメント担当以外のメンバーが
GitHubのドキュメントに間違いを 見つけた場合であっても、 devcontainer.jsonがあれば、 Codespace上でドキュメントを修正 して、プレビューを確認後にPull Requestを送るというプロセスが 容易になる。 チームの垣根を超えた コントリビュート
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric 社内の多くのリポジトリで
Codespacesの設定をしておくこと でチームの壁を超えたコントリ ビュートの敷居を低減 プリビルドを積極的に使うことで迅 速に開発環境を構築 CodespacesはGitHub社内での 標準開発環境 その過程で生み出された機能を Codespacesに組み込み まとめ
2022/08/31 How GitHub uses Codespaces Tech Stand #9 @yuichielectric Thank
you