No description
Find a file
2025-11-17 14:21:29 +09:00
_test init 2025-11-17 14:21:29 +09:00
api-gateway init 2025-11-17 14:21:29 +09:00
functions init 2025-11-17 14:21:29 +09:00
terraform init 2025-11-17 14:21:29 +09:00
workflows/workflow-create-minutes init 2025-11-17 14:21:29 +09:00
.gitignore init 2025-11-17 14:21:29 +09:00
cloudbuild_dev.yaml init 2025-11-17 14:21:29 +09:00
cloudbuild_prod.yaml init 2025-11-17 14:21:29 +09:00
README.md init 2025-11-17 14:21:29 +09:00
requirements.txt init 2025-11-17 14:21:29 +09:00

Sales Tool プロジェクト

概要

このリポジトリは、Sales Tool と呼ばれるシステムのバックエンドおよびインフラ構成を管理しています。主に以下のコンポーネントで構成されています。

  • API ゲートウェイOpenAPI 定義)
  • Google Cloud Functions各種ファンクション
  • ワークフロー定義Cloud Workflow
  • Terraform を使ったインフラ構成
  • テスト用スクリプト・データ

フォルダ構成

.
├── requirements.txt
├── api-gateway
│   ├── openapi_dev.yaml          # 開発環境用 OpenAPI 定義
│   └── openapi.yaml              # 本番環境用 OpenAPI 定義
├── functions                     # Cloud Functions 実装
│   ├── add-company
│   │   ├── _scripts
│   │   │   └── deploy_dev.sh     # デプロイスクリプト(開発環境)
│   │   └── source
│   │       ├── main.py
│   │       └── requirements.txt
│   ├── create-meeting-log-to-hubspot
│   │   └── source
│   │       └── main.py
│   ├── create-minutes
│   │   └── source
│   │       ├── main.py
│   │       └── requirements.txt
│   └── trigger-minutes-workflow-from-miitel
│       └── source
│           ├── main.py
│           └── requirements.txt
├── test                          # テスト用スクリプトとサンプルデータ
│   ├── main.py
│   ├── mst_company.csv
│   ├── request.json
│   ├── requirements.txt
│   └── __pycache__
│       └── main.cpython-38.pyc
├── terraform                     # インフラTerraform
│   └── dev
│       ├── main.tf
│       ├── terraform.tfstate
│       └── terraform.tfstate.backup
└── workflows                     # Cloud Workflow 定義
    └── workflow-create-minutes
        └── main.yaml

ディレクトリ詳細

  • api-gateway: OpenAPI 仕様ファイルを管理し、API ゲートウェイで使用。
  • functions: 各種 Google Cloud Functions のソースコードと依存定義。
  • test: ローカルでの動作確認やユニットテストに使用するスクリプト・データ。
  • terraform: Google Cloud 上のリソースStorage バケットなど)の構築をコード化。
  • workflows: Cloud Workflow の実行定義ファイル(.yaml)。

ローカル実行方法(概要)

  1. Python の依存インストール: pip install -r requirements.txt
  2. Functions のデプロイ: 各フォルダ内の deploy_dev.sh を実行
  3. Terraform 初期化・適用:
    cd terraform/dev && terraform init && terraform apply -auto-approve
    
  4. ワークフロー実行: Cloud Console または gcloud workflows CLI

詳細は各ディレクトリの README やコメントを参照してください。