Skip to content

Instantly share code, notes, and snippets.

@sanoyo
Last active May 8, 2021 14:22
Show Gist options
  • Save sanoyo/4e0ba85119c716d70f2c3d53c8edf909 to your computer and use it in GitHub Desktop.
Save sanoyo/4e0ba85119c716d70f2c3d53c8edf909 to your computer and use it in GitHub Desktop.
マイクロサービス メモ

マイクロサービス

マイクロサービス作るまでの道のり

機械学習とマイクロサービス

Istio

主な機能としては、サービス間の認証やモニタリング、L7での柔軟なロードバランシングが提供されています。

IstioはAPI Gatewayでも使用される

https://qiita.com/rawr/items/b9f01303e67aa0034bca#%E3%81%BE%E3%81%A8%E3%82%81%E3%81%A8%E3%81%84%E3%81%86%E3%82%88%E3%82%8A%E6%84%9F%E6%83%B3

API Gatewayについて

API Gatewayとは、クライアントから受け取ったリクエストを、それぞれのマイクロサービスにルーティングする仕組みのことです

マイクロサービスの種類

参考記事

http://microservices.io/patterns/apigateway.html

一旦kuberは無視で、docker-composeで作り切る

→自分が作りたいのって、API gateway のマイクロサービスパターン →よくわからなくなってきた

rails microservice

ひっかかったところ1: kubernetesを適用すると、画面が表示されない

docker

commitコマンド

containerの情報をimageに上書きできる

containerからimageを作成する

pruneコマンド

使用していないimage, containerなどを削除してくれる。

# noneも消去してくれる
docker image prune

全体的に

port

webサーバー、アプリケーションサーバー


最初にマイクロサービスを実装する際に参考になるgithub

https://github.com/PacktPublishing/Hands-on-Microservices-with-Python


マイクロサービス最初に目指す理想像

コード(github)

https://github.com/GoogleCloudPlatform/microservices-demo

内容

Googleが新しい技術とかを試すときに使用しているリポジトリらしい

インストール

  • リポジトリをcloneする
  • skaffold run 実行

※この記事に従って、すすめる。
https://skaffold.dev/docs/getting-started/#installing-skaffold

参考にした記事

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment