cloudcosting 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- cloudcosting-0.1.0/.github/workflows/ci.yaml +55 -0
- cloudcosting-0.1.0/.github/workflows/publish_to_pypi.yaml +30 -0
- cloudcosting-0.1.0/.gitignore +39 -0
- cloudcosting-0.1.0/.pre-commit-config.yaml +7 -0
- cloudcosting-0.1.0/LICENSE +674 -0
- cloudcosting-0.1.0/PKG-INFO +154 -0
- cloudcosting-0.1.0/PYPI_SETUP_GUIDE.md +409 -0
- cloudcosting-0.1.0/README.md +128 -0
- cloudcosting-0.1.0/design.yaml +405 -0
- cloudcosting-0.1.0/implementation_checklist.md +110 -0
- cloudcosting-0.1.0/pyproject.toml +62 -0
- cloudcosting-0.1.0/requirements.yaml +285 -0
- cloudcosting-0.1.0/src/cloudcosting/__init__.py +8 -0
- cloudcosting-0.1.0/src/cloudcosting/__main__.py +6 -0
- cloudcosting-0.1.0/src/cloudcosting/cache.py +110 -0
- cloudcosting-0.1.0/src/cloudcosting/cli.py +155 -0
- cloudcosting-0.1.0/src/cloudcosting/config.py +112 -0
- cloudcosting-0.1.0/src/cloudcosting/domain.py +159 -0
- cloudcosting-0.1.0/src/cloudcosting/estimator.py +104 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/__init__.py +0 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/__init__.py +0 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/calculators/__init__.py +0 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/calculators/alb.py +55 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/calculators/ebs.py +63 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/calculators/ec2.py +81 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/calculators/nat_gateway.py +52 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/calculators/rds.py +255 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/calculators/s3.py +59 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/pricing.py +164 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/aws/provider.py +112 -0
- cloudcosting-0.1.0/src/cloudcosting/providers/registry.py +26 -0
- cloudcosting-0.1.0/technical_design.yaml +688 -0
- cloudcosting-0.1.0/tests/__init__.py +1 -0
- cloudcosting-0.1.0/tests/integration/__init__.py +0 -0
- cloudcosting-0.1.0/tests/unit/__init__.py +0 -0
- cloudcosting-0.1.0/tests/unit/providers/__init__.py +0 -0
- cloudcosting-0.1.0/tests/unit/providers/aws/__init__.py +0 -0
- cloudcosting-0.1.0/tests/unit/providers/aws/test_calculators.py +174 -0
- cloudcosting-0.1.0/tests/unit/providers/aws/test_rds.py +111 -0
- cloudcosting-0.1.0/tests/unit/test_cache.py +107 -0
- cloudcosting-0.1.0/tests/unit/test_config.py +231 -0
- cloudcosting-0.1.0/tests/unit/test_domain.py +163 -0
- cloudcosting-0.1.0/tests/unit/test_estimator.py +237 -0
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main]
|
|
8
|
+
|
|
9
|
+
env:
|
|
10
|
+
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
lint:
|
|
14
|
+
name: Lint & Format
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v4
|
|
18
|
+
|
|
19
|
+
- name: Install uv
|
|
20
|
+
uses: astral-sh/setup-uv@v5
|
|
21
|
+
|
|
22
|
+
- name: Set up Python
|
|
23
|
+
run: uv python install 3.13
|
|
24
|
+
|
|
25
|
+
- name: Install dependencies
|
|
26
|
+
run: |
|
|
27
|
+
uv venv .venv
|
|
28
|
+
uv pip install -e ".[dev]"
|
|
29
|
+
|
|
30
|
+
- name: Ruff lint
|
|
31
|
+
run: uv run ruff check src/ tests/
|
|
32
|
+
|
|
33
|
+
- name: Ruff format check
|
|
34
|
+
run: uv run ruff format --check src/ tests/
|
|
35
|
+
|
|
36
|
+
test:
|
|
37
|
+
name: Test
|
|
38
|
+
runs-on: ubuntu-latest
|
|
39
|
+
needs: lint
|
|
40
|
+
steps:
|
|
41
|
+
- uses: actions/checkout@v4
|
|
42
|
+
|
|
43
|
+
- name: Install uv
|
|
44
|
+
uses: astral-sh/setup-uv@v5
|
|
45
|
+
|
|
46
|
+
- name: Set up Python
|
|
47
|
+
run: uv python install 3.13
|
|
48
|
+
|
|
49
|
+
- name: Install dependencies
|
|
50
|
+
run: |
|
|
51
|
+
uv venv .venv
|
|
52
|
+
uv pip install -e ".[dev]"
|
|
53
|
+
|
|
54
|
+
- name: Run tests
|
|
55
|
+
run: uv run pytest tests/ -v
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
name: Publish to PyPI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
|
|
7
|
+
env:
|
|
8
|
+
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
publish:
|
|
12
|
+
name: Build & Publish
|
|
13
|
+
runs-on: ubuntu-latest
|
|
14
|
+
environment: pypi
|
|
15
|
+
permissions:
|
|
16
|
+
id-token: write
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
|
|
20
|
+
- name: Install uv
|
|
21
|
+
uses: astral-sh/setup-uv@v5
|
|
22
|
+
|
|
23
|
+
- name: Set up Python
|
|
24
|
+
run: uv python install 3.13
|
|
25
|
+
|
|
26
|
+
- name: Build package
|
|
27
|
+
run: uv build
|
|
28
|
+
|
|
29
|
+
- name: Publish to PyPI
|
|
30
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Python
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
*.egg-info/
|
|
6
|
+
*.egg
|
|
7
|
+
dist/
|
|
8
|
+
build/
|
|
9
|
+
*.whl
|
|
10
|
+
|
|
11
|
+
# Virtual environments
|
|
12
|
+
.venv/
|
|
13
|
+
venv/
|
|
14
|
+
|
|
15
|
+
# Testing
|
|
16
|
+
.hypothesis/
|
|
17
|
+
.pytest_cache/
|
|
18
|
+
|
|
19
|
+
# Type checking
|
|
20
|
+
.mypy_cache/
|
|
21
|
+
|
|
22
|
+
# IDE
|
|
23
|
+
.idea/
|
|
24
|
+
.vscode/
|
|
25
|
+
*.swp
|
|
26
|
+
*.swo
|
|
27
|
+
|
|
28
|
+
# OS
|
|
29
|
+
.DS_Store
|
|
30
|
+
Thumbs.db
|
|
31
|
+
|
|
32
|
+
# Lock files (early lifecycle -- no lock files)
|
|
33
|
+
uv.lock
|
|
34
|
+
|
|
35
|
+
# Environment
|
|
36
|
+
.env
|
|
37
|
+
|
|
38
|
+
# Word temp files
|
|
39
|
+
~$*
|