Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 3 additions & 10 deletions app.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,32 +3,25 @@
from constructs_package.constants import AwsAccountId
from constructs_package.constants import AwsRegion
from constructs_package.constants import AwsStage

from infra.stack import CiCdStack


app = cdk.App()
CiCdStack(
scope=app,
id=f"CiCd-{AwsStage.SANDBOX}",
env=cdk.Environment(
account=AwsAccountId.SANDBOX, region=AwsRegion.US_EAST_1
),
env=cdk.Environment(account=AwsAccountId.SANDBOX, region=AwsRegion.US_EAST_1),
)

CiCdStack(
scope=app,
id=f"CiCd-{AwsStage.STAGING}",
env=cdk.Environment(
account=AwsAccountId.STAGING, region=AwsRegion.US_EAST_1
),
env=cdk.Environment(account=AwsAccountId.STAGING, region=AwsRegion.US_EAST_1),
)

CiCdStack(
scope=app,
id=f"CiCd-{AwsStage.PRODUCTION}",
env=cdk.Environment(
account=AwsAccountId.PRODUCTION, region=AwsRegion.US_EAST_1
),
env=cdk.Environment(account=AwsAccountId.PRODUCTION, region=AwsRegion.US_EAST_1),
)
app.synth()
6 changes: 2 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ optional = true
bandit = {version = "^1.7.4", extras = ["toml"]} # Security linter
black = "^23.6.0" # Python style checks
commitizen = "^3.12.0" # Check commit messages
cz-github-jira-conventional = "^2.0.0" # Extension to commitizen to check for JIRA ticket number
flake8 = "^6.1.0" # Style Guide Enforcement
flake8-annotations = "^3.0.1" # check for presence of type annotations in function definitions.
flake8-bugbear = "^23.9.16" # Finding likely bugs and design problems in your program.
Expand Down Expand Up @@ -176,9 +175,8 @@ omit = ["*/tests/*", "*/__init__.py", "*/*config.py"] # Remove test files fro
omit = ["*/tests/*", "*/__init__.py", "*/*config.py"] # Remove test files from coverage report.

[tool.commitizen]
ag_format = "$major.$minor.$patch$prerelease"
name = "conventional_commits"
tag_format = "$version"
version = "0.0.0"
version_files = [
"pyproject.toml:version",
]
]
1 change: 0 additions & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import pytest

from aws_cdk.assertions import Template

from infra.stack import CiCdStack


Expand Down
6 changes: 1 addition & 5 deletions tests/infra/test_stack.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,7 @@ def test_bucket(template: Template):
"VersioningConfiguration": {"Status": "Enabled"},
"BucketEncryption": {
"ServerSideEncryptionConfiguration": [
{
"ServerSideEncryptionByDefault": {
"SSEAlgorithm": "AES256"
}
}
{"ServerSideEncryptionByDefault": {"SSEAlgorithm": "AES256"}}
]
},
},
Expand Down
Loading