WASNight 2021 Kick-off OWASP Session
WASNight 2021 Kick-off OWASP Session
はじめに TL; DR; 社内の普段はインフラ以外のところを主戦場にしている人向けに、AWS・GCPの権限に関する用語と概念を説明するために書いたものを加筆訂正して公開します AWS・GCPの権限管理は、基本的な概念は似ているが同じ英単語が別の意味でつかわれているのでややこしい 書いてあること 概念の説明と、関係を表す図 EKS・GKEからクラウドリソース *1 を使う時の考え方 書いてないこと 設定のためのコンソール画面のスクショや手順 Kubernetesからクラウドリソースを操作する方法は、以前のブログ「GitHub Actionsで実現する、APIキー不要でGitOps-likeなインフラCI/CD」でTerraformによるコードの例も紹介しているので、あわせて参考にしてみてください 想定読者 AWSはそこそこ使って慣れているけど、GCPにおける権限管理を理解したい人(またはその
おうち Kubernetes をはじめて一週間が経ちましたが、やはり手元に3ノードある Kubernetes は便利ですね。早くマスターの HA 構成もしたいところです。 今回は、そんなおうち Kubernetes の認証を OpenID Connect で行うコトハジメをしてみたいと思います。 kubelogin を使ったログイン kubectl を使ったクラスタへのログインに kubelogin というプラグインを導入します。 これは OpenID Connect プロバイダから認証のリクエストを送り、プロバイダからもらった結果をプラグインに戻したのち、トークンを元に kube-apiserver へのリクエストを行います。その結果元に、クラスタの操作を行います。(そのためには権限を付与する必要がありますが) いわゆる GKE などでいう gcloud 認証情報ヘルパーのようなモノです
今回は前回と違いライトなネタです。 概要 Kubernetesで新しい脆弱性(CVE-2020-8554)が公開されました。 github.com 拍子抜けするほど簡単な脆弱性なのですが、一応試しておきました。発見者の方のブログも以下にあります。 blog.champtar.fr 今回の脆弱性はServiceのtype: LoadBalancer/ClusterIPを悪用して行う中間者攻撃(MITM)なのですが、ブログの中でMITM as a Serviceと評していたのが面白かったです。KubernetesがMITMを簡単に代行してくれるという意味でas a Service感強いですし、今回悪用するリソースタイプもServiceなので二重にかかっていて好きです。 要約 前提 攻撃者が以下のいずれかの権限を持つ場合 type: ClusterIPのServiceを作成可能かつspec.ex
はじめに 今朝に書いたブログが思ったより反響が大きくて、「Dockerが死んだ」という勘違いをされている方も多かったので追加でエントリーを書きました。 blog.inductor.me 決してそんなことはないので、対応が必要なケースを見ていこうと思います。 はじめに 対応が必要ではないケース Kubernetesを使わない人たち 本番はKubernetesでも、開発にDocker Composeを使っているデベロッパーの開発環境 対応が必要なケース 開発環境でも手元でKubernetesを利用する人たち NVIDIA DockerをKubernetesで使っている人たち Kubernetesワークロードの中で「Docker in Docker」や「Docker APIに依存した処理」を動かしている場合 Dockerの機能を使ってこれまでやっていたことについて 対応が必要ではないケース Ku
はじめに Kubernetes において、Pod を配置するための Node を決定する手続きをスケジューリングと呼び、デフォルトのクラスタでは kube-scheduler がその責務を担っています。本記事ではこの kube-scheduler のソースコードを時系列に沿って追いつつ、どのようなロジックで Pod を配置する Node が決定されるのかを解説します。 なお、本記事は Kubernetes の内部実装について学ぶ勉強会 Kubernetes Internal #3 の補足資料を意図して執筆されました。本文中で参照しているソースコードのバージョンは v1.19.4 です。 Kubernetes Internal #3 録画 スケジューラの概要 ソースコードを読むに先立つ予備知識として、スケジューリングの大まかな流れと Scheduling Framework の概要に触れてお
By Jorge Castro, Duffie Cooley, Kat Cosgrove, Justin Garrison, Noah Kantrowitz, Bob Killen, Rey Lejano, Dan “POP” Papandrea, Jeffrey Sica, Davanum “Dims” Srinivas | Wednesday, December 02, 2020 Update: Kubernetes support for Docker via dockershim is now removed. For more information, read the removal FAQ. You can also discuss the deprecation via a dedicated GitHub issue. Kubernetes is deprecating
こちらはLivesense アドベントカレンダー 2020 およびKubernetes3 アドベントカレンダー1日目の記事です。 こんにちは、転職会議のSREのかたいなかです。 転職会議では2020年の一年間をかけてインフラ基盤をECSからEKSに移行してきました。 この記事では構築したEKS基盤やECSからの移行の中で工夫した点を紹介します。 なぜEKS移行? 古くなっていたECS基盤を刷新する上で、ECSで再度作り直すのではなくEKSを選んだのは主に以下のような理由です。 IaCを更に推し進めGitOpsの考えを採用し、開発者がSREにレビュー以外で依存することなく主体的にインフラを変更できる状態を作るため ArgoやIstioといったKubernetesネイティブに開発されているツールを採用することでの恩恵を将来的に受けられるようにするため 純粋な技術的興味 採用を決めた当時は技術的
はじめに 「KubeCon + CloudNativeCon」でのセキュリティに関するセッションで紹介されたり、IstioをはじめとしたService MeshプロダクトのWorkload Identityとして採用されたりと、最近になりCloud NativeコミュニティでSPIFFEの名を耳にすることが多くなってきました。本記事では、SPIFFEが求められた背景やSPIFFEの概要、Kubernetesへの導入方法などを紹介していきます。 SPIFFEが求められた背景 マイクロサービスアーキテクチャ、コンテナオーケストレーター、クラウドコンピューティングのような分散システムを利用している環境では、サービスのスケーリングなどに伴いノードやアプリケーションが頻繁かつ動的に分散配置されるため、アプリケーションに割り当てられるIPアドレスが短期間で変化してきます。 このような環境では、ネットワ
Kubernetesのネットワークの構築要件に対して、世の中には様々なアプローチがあります。 本書ではTCP/IPは知っているけれど、Kubernetesのネットワークの実現方法は知らない人向けに、メジャーな実現アプローチについてできるだけ噛み砕いてステップバイステップで体系的に説明します。
こんにちは。スタディサプリ ENGLISH SREグループの木村です。 つい先日、スタディサプリENGLISHの基盤をECSからEKSへの移行をしました。移行の経緯や理由などは先日公開された大島のスタディサプリENGLISHの基盤をECSからEKSに移行しました という記事で紹介しております。 今回は私たちがKubernetesのCDに利用したArgo CDをなぜ選んだのか?どのよう導入したのかという部分を説明していきたいと思います。 Argo CDについて Argo CDはGitOps1)Gitをアプリケーションとインフラのsingle source of truthとして扱い、Gitにある情報(ここではKubernetesのmanifest)をあるべき姿とし、同期を行いアプリケーションの変更を行う手法。GitOpsを提唱しているweaveworksのGitOpsにページに詳細が書いてあ
ZOZOテクノロジーズSRE部の市橋です。普段は主にAWSを用いて複数プロダクトのシステム構築、運用に携わっています。今回は2020年2月にリリースされたZOZOMATについて、システム構成と開発時に直面した課題、その課題を解決するために工夫した点について紹介します。 ZOZOMATではEKSやgRPCを新規に採用しており、これによって仕様の変更に強くなる、通信のオーバーヘッドを削減できるなど様々なメリットを享受できました。しかし導入時に一筋縄ではいかないことがあったため、今回苦戦した点についてご紹介できればと思います。 ZOZOMATとは お客様の足を3Dで計測するために開発された計測用マットです。ZOZOMATでの計測情報をもとに、靴の推奨サイズを参照するなどのサービスをご利用いただくことが可能です。ご興味のある方はこちらをご確認ください。 ZOZOMATのシステム構成 システムの全体
こんにちは。HRBrainでインフラエンジニアをしている間野(@mano_0307)です。 今年の5月にインフラエンジニアとして入社しました。Kubernetesを使っている弊社で、Kubernetesをまったく触ったことのない私のような人間がインフラエンジニアになれるというのが弊社の素晴らしいところです。合言葉は「トライドリブン」。日々トライができる素晴らしい環境です。 Dev環境という各社共通の悩み 多くの会社で何かと困っているのがdev環境なのではないかと思います。 dev環境今日も空いてないよ・・・フルリモートでどうせバレないし、寝ちゃお あれ?久々に使ったdev5環境がうまく動かないよ。・・・(数時間後)あー、最新のmasterがrebaseされてないからAPIのinterface変わってんじゃん!うわー寝よ・・・ そろそろdev環境増やしたいな・・・でも、あの設定も複製しなきゃ
Goアプリケーション*4など、静的リンクしているバイナリでは利用できないsuidしたバイナリはTelepresence Shell内で動作しない/etc/resolv.confをパースするようなカスタムDNSリゾルバ、自身に対するDNS lookupは動かない *2:全制約事項についてはa href="https://www.telepresence.io/reference/methods" target="blank">公式ページを参照してください。 *3:LinuxのLD_PRELOADとmacOSのDYLD_INSERT_LIBRARIESを利用した方法で、詳細はこちらのブログで詳しく解説されています。 *4:go buildではなくgccgoによるビルドやGODEBUG環境変数でnetdnsのリゾルバをcgoに変更するなどのワークアラウンドは存在しますが、非推奨です。 *5:--
こんにちは。AI事業本部の青山(@amsy810)です。 2020年版「おうちKubernetesインターン」を実施したため、事後レポートをブログにまとめたいと思います。 コロナ禍のため、機材一式を学生とメンター宅に郵送し、フルリモートでの実施となりました。 またそれに合わせて3 Daysだったものを7 Daysに伸ばして、初日と最終日以外は夕会だけをコアタイムとしたフレックス性で実施しています。 メンターは私以外に、徳田、川部、漆田、源波、中西、岩立、長谷川が参加しています。 概要 今回のおうちKubernetesは Raspberry Pi 4 の 8GB モデル 3台 を使ってクラスタを構成しました。 単純な仕様だと、12 core + 24 GB Memory のクラスタです。もはやノートパソコンに近しい性能ですね。 また、今回 Raspberry Pi 4 になってから最低 2.
概要 ここ最近、Kubernetesクラスタを本番運用するにあたって負荷試験を行ってきました。 Kubernetesクラスタに乗せるアプリケーションの負荷試験は、通常の負荷試験でよく用いられる観点に加えて、クラスタ特有の観点も確認していく必要があります。 適切にクラスタやPodが設定されていない場合、意図しないダウンタイムが発生したり、想定する性能を出すことができません。 そこで私が設計した観点を、汎用的に様々なPJでも応用できるよう整理しました。 一定の負荷、スパイク的な負荷をかけつつ、主に下記の観点を重点的に記載します。 Podの性能 Podのスケーラビリティ クラスタのスケーラビリティ システムとしての可用性 本記事ではこれらの観点のチェックリスト的に使えるものとしてまとめてみます。 確認観点 攻撃ツール 1: ボトルネックになりえないこと Podレベル 2: 想定レイテンシでレスポ
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く