Skip to content

Commit

Permalink
pythonとさくらサーバについて追記
Browse files Browse the repository at this point in the history
  • Loading branch information
hoshi005 committed Nov 20, 2023
1 parent 6560955 commit a38b296
Show file tree
Hide file tree
Showing 3 changed files with 81 additions and 0 deletions.
5 changes: 5 additions & 0 deletions SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@

- [docker](server/docker.md)
- [GraphQL](server/graphql.md)
- [さくらサーバ](server/sakura.md)

## フロントエンド

Expand All @@ -106,6 +107,10 @@
- [React](react/react.md)
- [Next](react/next.md)

## Python

- [Python基礎](python/python.md)

## Android

- [Jetpack Compose](android/jetpack_compose.md)
Expand Down
18 changes: 18 additions & 0 deletions python/python.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Python基礎

## 環境作るなら

- pyenvを入れる
- brewで入れる
- pyenvでpythonを入れる
- pipはセットで入る
- この記事を参考にした
- [Pythonの開発環境を用意しよう!(Mac)](https://prog-8.com/docs/python-env)
- pipを確認
- pipはpythonとセットで入る
- pipのバージョンを確認
- `pip --version`
- pipのアップデート
- `pip install --upgrade pip`
- pipで入れたものは、globalに管理されるっぽい
- `pip list`
58 changes: 58 additions & 0 deletions server/sakura.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# さくらサーバを今後どうしていくか

さくらVPS
3つ

## サーバA

コスト: 15,000/年

image
http://ssssssssss.jpg
http://ssssssssss.json

> S3にする
> S3 標準 - 低頻度アクセス
> 標準 <-> 低頻度の切り替えも簡単
## サーバB

コスト: 800/月

railsで作ったAPI
railsで作った管理画面
Let's Encrypt
https://ssssss.ssssss

> API Gateway + Lambda
> parameter store なら無料
> 複雑ならDynamo
> S3にjsonをおいて、lambdaがそれを見にいく感じ
> バケットを分ける
## サーバC

コスト: 500/月

PDFのファイルサーバ
http://aaaaaaaaaaaaa.pdf

> S3にする
> S3 標準 - 低頻度アクセス
AWSでドメイン使うと $0.5/mon
S3のURLを、今と同じURLにすることも可能
URLが複雑で再現むずいなら、Cloud Front を使うこともできる
SSLするならCloud Front 必須、証明書はAWSがくれるはず
サービス断が一瞬発生(起きないかも)

お名前.comのドメイン設定を



native患者が存在している && 閲覧許可をしている場合 && アプリ導線がTrueになっている場合
patient_app_patient
and patient_app_patient.visible_pharmacy_admin
and request.user.pharmacy.visible_linkage_native_app


0 comments on commit a38b296

Please sign in to comment.