Terraform + Serverless deployment orchestrator
Project description
TFS Deploy
Terraform + Serverless deployment orchestrator for FaaS services.
Installation
pip install tfs-deploy
Usage
Deploy a service
# Deploy with default settings (dev stage, us-west-1 region)
tfs deploy
# Deploy to specific stage and region
tfs deploy --stage prod --region cn-beijing
# Skip certain steps
tfs deploy --skip-terraform --skip-tests
# Auto-approve Terraform changes
tfs deploy --auto-approve
Destroy infrastructure
tfs destroy --stage dev
Initialize a new project
tfs init
Project Structure
TFS Deploy expects the following structure:
my-service/
├── main.tf # Terraform infrastructure
├── s.yaml # Serverless configuration
├── .env # Environment variables
├── scripts/ # Deployment scripts
├── src/ # Source code
└── tests/
├── unit/ # Unit tests
└── integration/ # Integration tests
Environment Variables
STAGE- Deployment stage (dev, beta, prod)REGION- Cloud regionPROFILE- Cloud provider CLI profileTF_VAR_*- Terraform variables
How It Works
- Terraform: Applies infrastructure changes and exports outputs to
.env.terraform - s deploy: Runs
s deployfor function deployment - Integration Tests: Runs pytest on the deployed service
Example s.yaml
edition: 3.0.0
name: my-service
access: default
resources:
my-function:
component: fc3
props:
region: ${vars.region}
functionName: my-function-${vars.stage}
# ...
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
tfs_deploy-0.1.0.tar.gz
(4.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tfs_deploy-0.1.0.tar.gz.
File metadata
- Download URL: tfs_deploy-0.1.0.tar.gz
- Upload date:
- Size: 4.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
915c18fa71bbfc919113d3ed5d0941ff4bafc93bdbb7aa9874acb4484fcfb954
|
|
| MD5 |
ceed3e739cbbf9b4c4740bd3dc3c4c8b
|
|
| BLAKE2b-256 |
a76a4973ab5d4310c8f859d43121a5e562a2458db12ad9edbe22925a5d4bc471
|
File details
Details for the file tfs_deploy-0.1.0-py3-none-any.whl.
File metadata
- Download URL: tfs_deploy-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
af98795105b7d9ea5848fe53467d32d258e0a6720fc593303fcbec2d73e82c7a
|
|
| MD5 |
f51936677712bb41e30f470beebd1b3e
|
|
| BLAKE2b-256 |
48872f3cc962838b67d110cb4d1d299d81e99d4bb3bfd96b2d52f6807efafd25
|