atlas-init 0.4.0__py3-none-any.whl → 0.4.2__py3-none-any.whl
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.
- atlas_init/__init__.py +1 -1
- atlas_init/atlas_init.yaml +3 -0
- atlas_init/cli.py +1 -1
- atlas_init/cli_cfn/aws.py +2 -2
- atlas_init/cli_helper/go.py +104 -58
- atlas_init/cli_helper/run.py +3 -3
- atlas_init/cli_helper/run_manager.py +3 -3
- atlas_init/cli_root/go_test.py +13 -10
- atlas_init/cli_tf/app.py +4 -0
- atlas_init/cli_tf/debug_logs.py +3 -3
- atlas_init/cli_tf/example_update.py +142 -0
- atlas_init/cli_tf/example_update_test/test_update_example.tf +23 -0
- atlas_init/cli_tf/example_update_test.py +96 -0
- atlas_init/cli_tf/github_logs.py +6 -3
- atlas_init/cli_tf/go_test_run.py +24 -1
- atlas_init/cli_tf/go_test_summary.py +7 -1
- atlas_init/cli_tf/hcl/modifier.py +144 -0
- atlas_init/cli_tf/hcl/modifier_test/test_process_variables_output_.tf +25 -0
- atlas_init/cli_tf/hcl/modifier_test/test_process_variables_variable_.tf +24 -0
- atlas_init/cli_tf/hcl/modifier_test.py +95 -0
- atlas_init/cli_tf/hcl/parser.py +1 -1
- atlas_init/cli_tf/log_clean.py +29 -0
- atlas_init/cli_tf/schema_table.py +1 -3
- atlas_init/cli_tf/schema_v3.py +1 -1
- atlas_init/repos/path.py +14 -0
- atlas_init/settings/config.py +24 -13
- atlas_init/settings/env_vars.py +1 -1
- atlas_init/settings/env_vars_generated.py +1 -1
- atlas_init/settings/rich_utils.py +1 -1
- atlas_init/tf/.terraform.lock.hcl +16 -16
- atlas_init/tf/main.tf +25 -1
- atlas_init/tf/modules/aws_kms/aws_kms.tf +100 -0
- atlas_init/tf/modules/aws_kms/provider.tf +7 -0
- atlas_init/tf/modules/cfn/cfn.tf +1 -1
- atlas_init/tf/modules/cloud_provider/cloud_provider.tf +9 -2
- atlas_init/tf/modules/encryption_at_rest/main.tf +29 -0
- atlas_init/tf/modules/encryption_at_rest/provider.tf +9 -0
- atlas_init/tf/variables.tf +5 -0
- {atlas_init-0.4.0.dist-info → atlas_init-0.4.2.dist-info}/METADATA +13 -11
- {atlas_init-0.4.0.dist-info → atlas_init-0.4.2.dist-info}/RECORD +42 -31
- atlas_init/cli_tf/go_test_run_format.py +0 -31
- {atlas_init-0.4.0.dist-info → atlas_init-0.4.2.dist-info}/WHEEL +0 -0
- {atlas_init-0.4.0.dist-info → atlas_init-0.4.2.dist-info}/entry_points.txt +0 -0
@@ -21,7 +21,7 @@ class RealmSettings(_EnvVarsGenerated):
|
|
21
21
|
MONGODB_REALM_FUNCTION_ID: str
|
22
22
|
MONGODB_REALM_FUNCTION_NAME: str
|
23
23
|
MONGODB_REALM_BASE_URL: str
|
24
|
-
RANDOM_INT_100K: str = Field(default_factory=lambda: str(random.randint(0, 100_000))) # noqa: S311 # not used for cryptographic purposes
|
24
|
+
RANDOM_INT_100K: str = Field(default_factory=lambda: str(random.randint(0, 100_000))) # noqa: S311 # not used for cryptographic purposes # nosec
|
25
25
|
|
26
26
|
|
27
27
|
class EnvVarsGenerated(AtlasSettings):
|
@@ -36,7 +36,7 @@ def hide_secrets(handler: logging.Handler, secrets_dict: dict[str, str]) -> None
|
|
36
36
|
if not isinstance(value, str):
|
37
37
|
continue
|
38
38
|
key_lower = key.lower()
|
39
|
-
if key_lower in {"true", "false"} or value.lower() in {"true", "false"}:
|
39
|
+
if key_lower in {"true", "false"} or value.lower() in {"true", "false"} or value.isdigit():
|
40
40
|
continue
|
41
41
|
if any(safe in key_lower for safe in safe_keys):
|
42
42
|
continue
|
@@ -2,25 +2,25 @@
|
|
2
2
|
# Manual edits may be lost in future updates.
|
3
3
|
|
4
4
|
provider "registry.terraform.io/hashicorp/aws" {
|
5
|
-
version = "5.
|
5
|
+
version = "5.87.0"
|
6
6
|
constraints = "~> 5.0"
|
7
7
|
hashes = [
|
8
|
-
"h1:
|
9
|
-
"zh:
|
10
|
-
"zh:
|
11
|
-
"zh:
|
12
|
-
"zh:
|
13
|
-
"zh:
|
14
|
-
"zh:
|
15
|
-
"zh:
|
16
|
-
"zh:
|
8
|
+
"h1:IYq3by7O/eJuXzJwOF920z2nZEkw08PkDFdw2xkyhrs=",
|
9
|
+
"zh:017f237466875c919330b9e214fb33af14fffbff830d3755e8976d8fa3c963c2",
|
10
|
+
"zh:0776d1e60aa93c85ecbb01144aed2789c8e180bb0f1c811a0aba17ca7247b26c",
|
11
|
+
"zh:0dfa5c6cfb3724494fdc73f7d042515e88a20da8968959f48b3ec0b937bd8c8f",
|
12
|
+
"zh:1707a5ead36a7980cb3f83e8b69a67a14ae725bfc990ddfcc209b59400b57b04",
|
13
|
+
"zh:1c71f54fdd6adcbe547d6577dbb843d72a30fef0ab882d0afbeb8a7b348bc442",
|
14
|
+
"zh:3563c850a29790957ec3f4d3ba203bfa2e084ac7319035b3f43b91f818a2c9b4",
|
15
|
+
"zh:520bf6cef53785a92226651d5bebacbbf9314bdbc3211d0bf0903bce4e45149d",
|
16
|
+
"zh:56f9778575830f6e5c23462c2eccbf2c9afaddb00a69275fcfb33cd1a6d17f4d",
|
17
|
+
"zh:73e381cb0b1e76d471d7b0952f3d2a80350b507d15bda9b7041ea69077e3b5b5",
|
18
|
+
"zh:7da74b48f8fa088be758a92407980400cb4b039a8d9ba3c108907e4055e9ad6f",
|
19
|
+
"zh:8dacfa9623ba2e0197fe7db6faaaa0820a3b91fe00ba9e5d8a646340522bc8dd",
|
17
20
|
"zh:9b12af85486a96aedd8d7984b0ff811a4b42e3d88dad1a3fb4c0b580d04fa425",
|
18
|
-
"zh:
|
19
|
-
"zh:
|
20
|
-
"zh:
|
21
|
-
"zh:d6c76a24205513725269e4783da14be9648e9086fb621496052f4b37d52d785e",
|
22
|
-
"zh:d95a31745affb178ea48fa8e0be94691a8f7507ea55c0d0a4b6e0a8ef6fcb929",
|
23
|
-
"zh:f061ce59fac1bc425c1092e6647ed4bb1b61824416041b46dbf336e01a63ad89",
|
21
|
+
"zh:9c2ebd21d697e1a611fe201788dc9e1678949a088afc85d4589563bca484d835",
|
22
|
+
"zh:ac5d0bbf36f9a6cedbfb63993f6baf0aabdaf21c8d7fc3b1e69ba8cbf344b5f3",
|
23
|
+
"zh:c2329644179f78a0458b6cf2dd5eaadca4c610fc3577a1b50620544d92df13e8",
|
24
24
|
]
|
25
25
|
}
|
26
26
|
|
atlas_init/tf/main.tf
CHANGED
@@ -5,7 +5,8 @@ locals {
|
|
5
5
|
Owner = "terraform-atlas-init"
|
6
6
|
}
|
7
7
|
use_aws_vpc = var.use_private_link || var.use_vpc_peering || var.use_aws_vpc
|
8
|
-
|
8
|
+
use_aws_kms = var.use_encryption_at_rest
|
9
|
+
use_cloud_provider = var.use_aws_s3 || var.use_encryption_at_rest
|
9
10
|
# https://www.mongodb.com/docs/atlas/reference/amazon-aws/
|
10
11
|
atlas_region = replace(upper(var.aws_region), "-", "_")
|
11
12
|
use_cluster = var.cluster_config.name != ""
|
@@ -133,6 +134,18 @@ module "aws_s3" {
|
|
133
134
|
iam_role_name = module.cloud_provider[0].iam_role_name
|
134
135
|
}
|
135
136
|
|
137
|
+
module "aws_kms" {
|
138
|
+
source = "./modules/aws_kms"
|
139
|
+
count = local.use_aws_kms ? 1 : 0
|
140
|
+
|
141
|
+
access_iam_role_arns = {
|
142
|
+
atlas = module.cloud_provider[0].iam_role_arn
|
143
|
+
}
|
144
|
+
aws_account_id = local.aws_account_id
|
145
|
+
aws_region = var.aws_region
|
146
|
+
key_suffix = var.project_name
|
147
|
+
}
|
148
|
+
|
136
149
|
module "federated_vars" {
|
137
150
|
source = "./modules/federated_vars"
|
138
151
|
count = var.use_federated_vars ? 1 : 0
|
@@ -142,3 +155,14 @@ module "federated_vars" {
|
|
142
155
|
project_id = local.project_id
|
143
156
|
base_url = var.atlas_base_url
|
144
157
|
}
|
158
|
+
|
159
|
+
module "encryption_at_rest" {
|
160
|
+
source = "./modules/encryption_at_rest"
|
161
|
+
count = var.use_encryption_at_rest ? 1 : 0
|
162
|
+
|
163
|
+
project_id = local.project_id
|
164
|
+
atlas_role_id = module.cloud_provider[0].atlas_role_id
|
165
|
+
kms_key_id = module.aws_kms[0].kms_key_id
|
166
|
+
atlas_regions = [local.atlas_region]
|
167
|
+
|
168
|
+
}
|
@@ -0,0 +1,100 @@
|
|
1
|
+
variable "aws_account_id" {
|
2
|
+
type = string
|
3
|
+
}
|
4
|
+
variable "aws_region" {
|
5
|
+
type = string
|
6
|
+
}
|
7
|
+
variable "access_iam_role_arns" {
|
8
|
+
type = map(string)
|
9
|
+
description = "static name to arn"
|
10
|
+
}
|
11
|
+
|
12
|
+
variable "key_suffix" {
|
13
|
+
type = string
|
14
|
+
}
|
15
|
+
|
16
|
+
locals {
|
17
|
+
kms_secretsmanager_condition = {
|
18
|
+
StringEquals = {
|
19
|
+
"kms:CallerAccount" = var.aws_account_id
|
20
|
+
"kms:ViaService" = "secretsmanager.${var.aws_region}.amazonaws.com"
|
21
|
+
}
|
22
|
+
}
|
23
|
+
role_names = { for static_name, role_arn in var.access_iam_role_arns : split("/", role_arn)[length(split("/", role_arn)) - 1] => role_arn }
|
24
|
+
kms_key_policy_statements = [
|
25
|
+
{
|
26
|
+
Sid = "Enable IAM User Permissions Current AWS Account",
|
27
|
+
Effect = "Allow",
|
28
|
+
Principal = {
|
29
|
+
AWS = var.aws_account_id
|
30
|
+
},
|
31
|
+
Action = "kms:*",
|
32
|
+
Resource = "*"
|
33
|
+
},
|
34
|
+
# { useful to check our example guide
|
35
|
+
# "Sid" : "Allow access through AWS Secrets Manager for all principals in the account that are authorized to use AWS Secrets Manager",
|
36
|
+
# "Effect" : "Allow",
|
37
|
+
# # "Principal" : { "AWS" : [aws_iam_role.execution_role.arn] },
|
38
|
+
# "Principal" : { "AWS" : "*" },
|
39
|
+
# "Action" : [
|
40
|
+
# "kms:Decrypt",
|
41
|
+
# ],
|
42
|
+
# "Resource" : "*",
|
43
|
+
# "Condition" : local.kms_secretsmanager_condition
|
44
|
+
# },
|
45
|
+
]
|
46
|
+
|
47
|
+
access_roles = [for role_name, role_arn in local.role_names :
|
48
|
+
{
|
49
|
+
Sid = "Enable IAM Permissions for Role ${role_name}",
|
50
|
+
Effect = "Allow",
|
51
|
+
Principal = {
|
52
|
+
AWS = "*"
|
53
|
+
}
|
54
|
+
Action = "kms:*",
|
55
|
+
Resource = "*"
|
56
|
+
Condition = {
|
57
|
+
StringEquals = {
|
58
|
+
"aws:PrincipalArn" = role_arn
|
59
|
+
}
|
60
|
+
}
|
61
|
+
}
|
62
|
+
]
|
63
|
+
kms_key_policy_json = jsonencode({
|
64
|
+
Version = "2012-10-17",
|
65
|
+
Statement = concat(local.kms_key_policy_statements, local.access_roles)
|
66
|
+
})
|
67
|
+
}
|
68
|
+
resource "aws_kms_key" "this" {
|
69
|
+
description = "KMS key for atlas-init ${var.key_suffix}"
|
70
|
+
deletion_window_in_days = 7
|
71
|
+
multi_region = true
|
72
|
+
policy = local.kms_key_policy_json
|
73
|
+
}
|
74
|
+
|
75
|
+
resource "aws_iam_role_policy" "kms_access" {
|
76
|
+
for_each = var.access_iam_role_arns
|
77
|
+
name = "atlas-init-${each.key}-kms-access"
|
78
|
+
role = split("/", each.value)[length(split("/", each.value)) - 1]
|
79
|
+
|
80
|
+
policy = <<-EOF
|
81
|
+
{
|
82
|
+
"Version": "2012-10-17",
|
83
|
+
"Statement": [
|
84
|
+
{
|
85
|
+
"Effect": "Allow",
|
86
|
+
"Action": [
|
87
|
+
"kms:*"
|
88
|
+
],
|
89
|
+
"Resource": [
|
90
|
+
"${aws_kms_key.this.arn}"
|
91
|
+
]
|
92
|
+
}
|
93
|
+
]
|
94
|
+
}
|
95
|
+
EOF
|
96
|
+
}
|
97
|
+
|
98
|
+
output "kms_key_id" {
|
99
|
+
value = aws_kms_key.this.id
|
100
|
+
}
|
atlas_init/tf/modules/cfn/cfn.tf
CHANGED
@@ -11,7 +11,7 @@ locals {
|
|
11
11
|
resource_actions_yaml = file("${path.module}/resource_actions.yaml")
|
12
12
|
services = yamldecode(local.services_yaml)
|
13
13
|
resource_actions = yamldecode(local.resource_actions_yaml)
|
14
|
-
role_name = "
|
14
|
+
role_name = "mongodb-atlas-cfn-${var.cfn_profile}"
|
15
15
|
iam_policy_statement = {
|
16
16
|
Sid = "Original"
|
17
17
|
Action = local.resource_actions
|
@@ -22,7 +22,7 @@ resource "mongodbatlas_cloud_provider_access_authorization" "auth_role" {
|
|
22
22
|
|
23
23
|
|
24
24
|
resource "aws_iam_role" "aws_role" {
|
25
|
-
name = "
|
25
|
+
name = "mongodb-atlas-ainit-${var.name_suffix}"
|
26
26
|
|
27
27
|
assume_role_policy = <<EOF
|
28
28
|
{
|
@@ -53,7 +53,14 @@ output "env_vars" {
|
|
53
53
|
}
|
54
54
|
}
|
55
55
|
|
56
|
-
|
57
56
|
output "iam_role_name" {
|
58
57
|
value = aws_iam_role.aws_role.name
|
58
|
+
}
|
59
|
+
|
60
|
+
output "atlas_role_id" {
|
61
|
+
value = mongodbatlas_cloud_provider_access_authorization.auth_role.role_id
|
62
|
+
}
|
63
|
+
|
64
|
+
output "iam_role_arn" {
|
65
|
+
value = aws_iam_role.aws_role.arn
|
59
66
|
}
|
@@ -0,0 +1,29 @@
|
|
1
|
+
variable "atlas_regions" {
|
2
|
+
type = list(string)
|
3
|
+
default = ["US_EAST_1"]
|
4
|
+
}
|
5
|
+
|
6
|
+
variable "kms_key_id" {
|
7
|
+
type = string
|
8
|
+
}
|
9
|
+
variable "project_id" {
|
10
|
+
type = string
|
11
|
+
}
|
12
|
+
|
13
|
+
variable "atlas_role_id" {
|
14
|
+
type = string
|
15
|
+
}
|
16
|
+
|
17
|
+
resource "mongodbatlas_encryption_at_rest" "this" {
|
18
|
+
project_id = var.project_id
|
19
|
+
dynamic "aws_kms_config" {
|
20
|
+
for_each = var.atlas_regions
|
21
|
+
content {
|
22
|
+
enabled = true
|
23
|
+
customer_master_key_id = var.kms_key_id
|
24
|
+
region = aws_kms_config.value
|
25
|
+
role_id = var.atlas_role_id
|
26
|
+
|
27
|
+
}
|
28
|
+
}
|
29
|
+
}
|
atlas_init/tf/variables.tf
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: atlas-init
|
3
|
-
Version: 0.4.
|
3
|
+
Version: 0.4.2
|
4
4
|
Project-URL: Documentation, https://github.com/EspenAlbert/atlas-init#readme
|
5
5
|
Project-URL: Issues, https://github.com/EspenAlbert/atlas-init/issues
|
6
6
|
Project-URL: Source, https://github.com/EspenAlbert/atlas-init
|
@@ -11,19 +11,21 @@ Classifier: Programming Language :: Python
|
|
11
11
|
Classifier: Programming Language :: Python :: 3.12
|
12
12
|
Requires-Python: >=3.12
|
13
13
|
Requires-Dist: appdirs==1.4.4
|
14
|
-
Requires-Dist: boto3==1.
|
14
|
+
Requires-Dist: boto3==1.35.92
|
15
15
|
Requires-Dist: gitpython==3.1.42
|
16
16
|
Requires-Dist: humanize==4.9.0
|
17
|
-
Requires-Dist: model-lib==
|
18
|
-
Requires-Dist: mypy-boto3-cloudformation==1.
|
19
|
-
Requires-Dist: orjson==3.
|
20
|
-
Requires-Dist: pydantic-settings==2.
|
21
|
-
Requires-Dist: pygithub==2.
|
22
|
-
Requires-Dist:
|
23
|
-
Requires-Dist:
|
17
|
+
Requires-Dist: model-lib[toml]==1.0.0b3
|
18
|
+
Requires-Dist: mypy-boto3-cloudformation==1.37.22
|
19
|
+
Requires-Dist: orjson==3.10.13
|
20
|
+
Requires-Dist: pydantic-settings==2.7.1
|
21
|
+
Requires-Dist: pygithub==2.6.1
|
22
|
+
Requires-Dist: python-hcl2==6.1.0
|
23
|
+
Requires-Dist: requests==2.32.2
|
24
|
+
Requires-Dist: rich==14.0.0
|
24
25
|
Requires-Dist: stringcase==1.2.0
|
25
|
-
Requires-Dist: tenacity==
|
26
|
-
Requires-Dist: typer==0.
|
26
|
+
Requires-Dist: tenacity==9.0.0
|
27
|
+
Requires-Dist: typer==0.15.1
|
28
|
+
Requires-Dist: zero-3rdparty==1.0.0b2
|
27
29
|
Description-Content-Type: text/markdown
|
28
30
|
|
29
31
|
# Atlas Init - A CLI for developing integrations with MongoDB Atlas
|
@@ -1,88 +1,99 @@
|
|
1
|
-
atlas_init/__init__.py,sha256=
|
1
|
+
atlas_init/__init__.py,sha256=mdnD1EIENrrNoygcsXJXBVXaCItR3hi-Eys2B7KqVoM,372
|
2
2
|
atlas_init/__main__.py,sha256=dY1dWWvwxRZMmnOFla6RSfti-hMeLeKdoXP7SVYqMUc,52
|
3
|
-
atlas_init/atlas_init.yaml,sha256=
|
4
|
-
atlas_init/cli.py,sha256=
|
3
|
+
atlas_init/atlas_init.yaml,sha256=Q_gFMbTa8OKxS8GbjszyrMA05nap8HI_Oe-cgQZNEPk,2351
|
4
|
+
atlas_init/cli.py,sha256=znbyirZl_tChG4SoGQPEM5iSsJiSVslCdExSja1qvUo,9262
|
5
5
|
atlas_init/cli_args.py,sha256=tiwUYAE0JBSl9lHV6VJ41vFCU90ChBZ4mKvi-YoF_HY,541
|
6
6
|
atlas_init/humps.py,sha256=l0ZXXuI34wwd9TskXhCjULfGbUyK-qNmiyC6_2ow6kU,7339
|
7
7
|
atlas_init/terraform.yaml,sha256=qPrnbzBEP-JAQVkYadHsggRnDmshrOJyiv0ckyZCxwY,2734
|
8
8
|
atlas_init/typer_app.py,sha256=RjOZRIV-hacWksgjLB0ip4DgA1fz5x-yHRWuSwSGEws,4254
|
9
9
|
atlas_init/cli_cfn/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
10
10
|
atlas_init/cli_cfn/app.py,sha256=DCwEp7kwJMytuy13jHr2M1jJ6sMWTthOc-LkHtNvoew,6104
|
11
|
-
atlas_init/cli_cfn/aws.py,sha256=
|
11
|
+
atlas_init/cli_cfn/aws.py,sha256=KtJWJmYDknPFtd4j6evMFRwmnFGcLYUFHArV6J49TjI,17911
|
12
12
|
atlas_init/cli_cfn/cfn_parameter_finder.py,sha256=tAadNF1M_U2BTY-m9fXVXFXNQRvfudOja97jT3AiVaI,10811
|
13
13
|
atlas_init/cli_cfn/contract.py,sha256=6gRCvKRh6bn6BiQ3wyai_XNUwbWSqSRlg5GFvSdEcRc,7886
|
14
14
|
atlas_init/cli_cfn/example.py,sha256=_JuFyNEb7QvD4T8jQyAPI3TgnHW0wz0kVuncB5UkbEA,8530
|
15
15
|
atlas_init/cli_cfn/files.py,sha256=kwKDh__O__it2Shz3pHhnle4XUesRd4P929twxUODfI,2651
|
16
16
|
atlas_init/cli_helper/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
17
|
-
atlas_init/cli_helper/go.py,sha256=
|
18
|
-
atlas_init/cli_helper/run.py,sha256=
|
19
|
-
atlas_init/cli_helper/run_manager.py,sha256=
|
17
|
+
atlas_init/cli_helper/go.py,sha256=WN3p7GXQNDtDl1M3rJ1Qhv2mz89Jow0BWucHnwLfUQs,9725
|
18
|
+
atlas_init/cli_helper/run.py,sha256=va1eFP-hRvM76lVzvqH8eqGnyfcbzgR0zCMbL9Neb58,3660
|
19
|
+
atlas_init/cli_helper/run_manager.py,sha256=USNRHSm1zuu4H9NRamnxQ2D4gKzrHLk8dZe0G95Be14,9022
|
20
20
|
atlas_init/cli_helper/sdk.py,sha256=exh58-VZwxtosaxM269C62EEy1VnpJPOVziPDPkGsmE,2983
|
21
21
|
atlas_init/cli_helper/sdk_auto_changes.py,sha256=oWyXw7P0PdO28hclRvza_RcIVXAyzu0lCYTJTNBDMeo,189
|
22
22
|
atlas_init/cli_helper/tf_runner.py,sha256=ZEh4WlI-6RV84uBtGNcFgAr8M03As-BLz4fu9wCPULw,3327
|
23
23
|
atlas_init/cli_root/__init__.py,sha256=Mf0wqy4kqq8pmbjLa98zOGuUWv0bLk2OYGc1n1_ZmZ4,223
|
24
|
-
atlas_init/cli_root/go_test.py,sha256=
|
24
|
+
atlas_init/cli_root/go_test.py,sha256=roQIOS-qVfNhJMztR-V3hjtxFMf7-Ioy3e1ffqtTRyo,4601
|
25
25
|
atlas_init/cli_root/trigger.py,sha256=In3oS-z8gYYsPxQjHsGmqB1AsUtHPDTxwva5arsajvU,8227
|
26
26
|
atlas_init/cli_tf/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
27
|
-
atlas_init/cli_tf/app.py,sha256=
|
27
|
+
atlas_init/cli_tf/app.py,sha256=6dFc9NMaM25vC4BMa8HCDDks9dD74nwauD70GnWBmZU,11600
|
28
28
|
atlas_init/cli_tf/changelog.py,sha256=biWYKf1pZvXZ-jEgcZ5q9sY7nTGrL2PuI0h9mCILf_g,3181
|
29
|
-
atlas_init/cli_tf/debug_logs.py,sha256=
|
29
|
+
atlas_init/cli_tf/debug_logs.py,sha256=P78XnlvBj0rBSceLF3nIuHPIRBnKKw1Ya2gY2zkbTsU,10046
|
30
30
|
atlas_init/cli_tf/debug_logs_test_data.py,sha256=s85x78pFweVyqL2BchkLuvuG9hm-bwl8zcSO-IQqm6c,9736
|
31
31
|
atlas_init/cli_tf/debug_logs_test_data_package_config.py,sha256=BOAgln1pWne_ZhP6a0SM2ddn2csr0sgGkYf2kMS_V9o,1666
|
32
|
-
atlas_init/cli_tf/
|
33
|
-
atlas_init/cli_tf/
|
34
|
-
atlas_init/cli_tf/
|
35
|
-
atlas_init/cli_tf/
|
32
|
+
atlas_init/cli_tf/example_update.py,sha256=xCXm6n0fSfPCnv9GyXBfPz7ljFe8Y4WPFZaXf_qDa68,5254
|
33
|
+
atlas_init/cli_tf/example_update_test.py,sha256=EI_6ZsOaGt7iX2JvJ3rvv3B2zKRRjI-d3P8R-tvgFc8,2859
|
34
|
+
atlas_init/cli_tf/github_logs.py,sha256=jJs74npytc7f_nxmUG_CgWpBrKCuF5nZtpwsSii-3XY,8365
|
35
|
+
atlas_init/cli_tf/go_test_run.py,sha256=BrEX-U7wGd4pV_PZycttbbBgG2ac0vOLeJwm65zFTmo,7420
|
36
|
+
atlas_init/cli_tf/go_test_summary.py,sha256=4hPjT5gKRixXWO6NtTRkavDXPIZmC0TJ-7GhN2h33H0,5590
|
37
|
+
atlas_init/cli_tf/log_clean.py,sha256=lVbw6fDstr9HanGVEv6zBcfs_4aR2TcPHCIx1poU5sY,926
|
36
38
|
atlas_init/cli_tf/mock_tf_log.py,sha256=-ZOtQmy9w7k7HvrywMqlgohZ6Kerojk-P_xtiTaZ4sc,7555
|
37
39
|
atlas_init/cli_tf/schema.py,sha256=iwvb4wD2Wba0MMu7ooTNAIi1jHbpLiXGPOT51_o_YW8,12431
|
38
40
|
atlas_init/cli_tf/schema_go_parser.py,sha256=PiRfFFVnkhltxcGFfOCgH53wwzIEynw2BXmSfaINLL8,8294
|
39
41
|
atlas_init/cli_tf/schema_inspection.py,sha256=ujLvGfg3baByND4nRD0drZoI45STxo3VfYvim-PfVOc,1764
|
40
|
-
atlas_init/cli_tf/schema_table.py,sha256=
|
42
|
+
atlas_init/cli_tf/schema_table.py,sha256=sxH-WUvBOHPI-HH2-2Y_MwKN-_POlQX3599h6YbfY1U,5261
|
41
43
|
atlas_init/cli_tf/schema_table_models.py,sha256=9gS3gYris0MjEWsY_gbLWcZwJokCUJS1TcVXnq7w5SA,5003
|
42
44
|
atlas_init/cli_tf/schema_v2.py,sha256=NtVW3lPKxHtCMBEwo9zThARpy9oQRbsKd0NrhymAyyE,21960
|
43
45
|
atlas_init/cli_tf/schema_v2_api_parsing.py,sha256=8XtwHNU84VPMATD3CbE-TLeVlgxqZggxY5QQ5YjhX4w,12888
|
44
46
|
atlas_init/cli_tf/schema_v2_sdk.py,sha256=AsAERT18FC97Gdb8r-qFInr4pSA15IGMUvCn-065XGE,12630
|
45
|
-
atlas_init/cli_tf/schema_v3.py,sha256=
|
47
|
+
atlas_init/cli_tf/schema_v3.py,sha256=LUeI2kniUDfd-5iP1TCLXb-Js92VYSXB6FCVLDYAIak,5788
|
46
48
|
atlas_init/cli_tf/schema_v3_sdk.py,sha256=5RWbhqKT8jEGgJrQaaT7xTRToviIzZZOxuJO5MNLYwo,9929
|
47
49
|
atlas_init/cli_tf/schema_v3_sdk_base.py,sha256=oe7WRZc0R_UYP5Yry4kDAMxOKAUHvQrc9bIdjfLshYk,2131
|
48
50
|
atlas_init/cli_tf/schema_v3_sdk_create.py,sha256=64AluGbQP47RRdY6Cz4KZRN9DdQISW5lLxQ-E1od5dc,8342
|
51
|
+
atlas_init/cli_tf/example_update_test/test_update_example.tf,sha256=Bun55357kL84VuWpVx7XvpZHndkY6s8VfFPGAkK_DzA,524
|
49
52
|
atlas_init/cli_tf/hcl/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
50
53
|
atlas_init/cli_tf/hcl/cli.py,sha256=6V1kU_a1c4LA3rS7sWN821gQex00fb70AUyd07xO0es,5760
|
51
54
|
atlas_init/cli_tf/hcl/cluster_mig.py,sha256=kMb_0V_XWr_iQj-mZZ-mmzIvYOLfuC4FYGYYSe9VKkQ,12496
|
52
|
-
atlas_init/cli_tf/hcl/
|
55
|
+
atlas_init/cli_tf/hcl/modifier.py,sha256=zmfHgRR48IECF-8Pj915kCjM0VrW2KAAQu1KDDgDF9Y,4817
|
56
|
+
atlas_init/cli_tf/hcl/modifier_test.py,sha256=Jdqa-iZ1ifbz_yIsjD055meFMZJpetx_abg1W4LVBZ8,2740
|
57
|
+
atlas_init/cli_tf/hcl/parser.py,sha256=wqj0YIn9nyEfjRqZnM7FH4yL43-K9ANvRiy9RCahImc,4833
|
58
|
+
atlas_init/cli_tf/hcl/modifier_test/test_process_variables_output_.tf,sha256=GMRAFFlBWOg8Fu5mQDMIA7SWD-sSjkCBe__gIsop3mA,646
|
59
|
+
atlas_init/cli_tf/hcl/modifier_test/test_process_variables_variable_.tf,sha256=2vVCTHkqP0aud1EA428LMsPnUeTRYGFkb3RlDxsKszk,605
|
53
60
|
atlas_init/cloud/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
54
61
|
atlas_init/cloud/aws.py,sha256=AXVobJ724S6OeEs_uXH9dvecc_klnXqejRnI7KaLyzo,4935
|
55
62
|
atlas_init/repos/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
56
63
|
atlas_init/repos/cfn.py,sha256=rjyVVxRhWL65tdAbEHT72UReK2h99Bj6RA4O2pBO-bc,2466
|
57
64
|
atlas_init/repos/go_sdk.py,sha256=1OzM9DjHEAzAAuI9ygoRRuhUK2gqpOhXExXRqhqa0tg,1793
|
58
|
-
atlas_init/repos/path.py,sha256=
|
65
|
+
atlas_init/repos/path.py,sha256=5XsXrxpyQi2bkV_qOtbIhL7-XGwW68XUmCTOdyfoz1A,4517
|
59
66
|
atlas_init/settings/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
60
|
-
atlas_init/settings/config.py,sha256=
|
61
|
-
atlas_init/settings/env_vars.py,sha256=
|
62
|
-
atlas_init/settings/env_vars_generated.py,sha256=
|
67
|
+
atlas_init/settings/config.py,sha256=Cb483vmKOnNUK6m5KlhDiGeDJcZoJ1vHREdiddYONuQ,7037
|
68
|
+
atlas_init/settings/env_vars.py,sha256=1M4EKveUbrHaEuSyWyZ_bdK7MUTHhBu8-tFGSimqCCI,10659
|
69
|
+
atlas_init/settings/env_vars_generated.py,sha256=c3dMShnSvqLsiJTIMoHCpC9Tvk35b5lra40Ske9l4gE,980
|
63
70
|
atlas_init/settings/interactive.py,sha256=Xy1Z5WMAOSaJ-vQI_4xjAbSR92rWQgnffwVoDT27L68,340
|
64
71
|
atlas_init/settings/path.py,sha256=KkXysu6-0AuSjsvYGknYGJX1hL2j1RD-Fpf8KsVYpkE,2618
|
65
|
-
atlas_init/settings/rich_utils.py,sha256=
|
66
|
-
atlas_init/tf/.terraform.lock.hcl,sha256=
|
72
|
+
atlas_init/settings/rich_utils.py,sha256=mjYCZ7Sx-OTsjv7AZ4qyjXqvq3TOaczLfDjOQK_dKWk,2012
|
73
|
+
atlas_init/tf/.terraform.lock.hcl,sha256=71G7Kov2C4M0qOIyeIL90Vw8j8nkJktNUT3uPwUOu5w,6876
|
67
74
|
atlas_init/tf/always.tf,sha256=ij6QKI8Lg0140bFZwOyiYK5c-2p5e7AGZ1qKbYyv6Os,1359
|
68
|
-
atlas_init/tf/main.tf,sha256=
|
75
|
+
atlas_init/tf/main.tf,sha256=Et2j61c33rWYh2V889ThmoGi1HGnyTxSwsBfgTJc0B0,4641
|
69
76
|
atlas_init/tf/outputs.tf,sha256=Jd1n-rNt0cv-tqXEXaFxJQE7poR_T7FAKEVuhAJd3aE,3857
|
70
77
|
atlas_init/tf/providers.tf,sha256=ayfaz4nekzWzUuH56lZzrJTX1025Wej-xzt0Yi80Uh8,819
|
71
|
-
atlas_init/tf/variables.tf,sha256=
|
78
|
+
atlas_init/tf/variables.tf,sha256=f1WiFPDDYbn7h1HRJGQJ0uOWWBF2t4h4uVPjpQl57_Y,2169
|
79
|
+
atlas_init/tf/modules/aws_kms/aws_kms.tf,sha256=SpegPwvVMRWgyRbTcZjMMVqE6cHBPbJ1rX5Gz6dUd3c,2531
|
80
|
+
atlas_init/tf/modules/aws_kms/provider.tf,sha256=V0QcTh2IQWr33kcHKG0m_qxapRwIT8_HrMtfylEJBVU,90
|
72
81
|
atlas_init/tf/modules/aws_s3/aws_s3.tf,sha256=SP5vZf5Y2g9Z5yWpBKSKzEEF5FITPycoGKe-kaHoVCI,738
|
73
82
|
atlas_init/tf/modules/aws_s3/provider.tf,sha256=RmUmMzMfOT5LZIWYqxM2EgtkI7JWqZfj3p3TxZkZoLk,161
|
74
83
|
atlas_init/tf/modules/aws_vars/aws_vars.tf,sha256=0SItDIZUWQCpw4o0y2jZjUY1LnUeUdAL2wOjng3GDtc,508
|
75
84
|
atlas_init/tf/modules/aws_vpc/aws_vpc.tf,sha256=TnWyDFLHi_aYEnqRCNLDjQmCSUPA0x_4A9fCvXL0vO0,1838
|
76
85
|
atlas_init/tf/modules/aws_vpc/provider.tf,sha256=0c2_hW9dSnwbK_1xdD4iSLiD6PACneBx5rEW06uWYlM,210
|
77
86
|
atlas_init/tf/modules/cfn/assume_role_services.yaml,sha256=Sv-FPsLeZ0K_3x0Eq5iJcf7yGe5ax8I0uqzvUlMZDOY,94
|
78
|
-
atlas_init/tf/modules/cfn/cfn.tf,sha256=
|
87
|
+
atlas_init/tf/modules/cfn/cfn.tf,sha256=ajBFLh0RYwAqRhp9-yanYKqfjNus0r88_gxRFdFfEj4,3019
|
79
88
|
atlas_init/tf/modules/cfn/kms.tf,sha256=W-HfFbQ2J1GQC279Ou-PLq4huf0mGn235BCEgO7n9aI,1635
|
80
89
|
atlas_init/tf/modules/cfn/resource_actions.yaml,sha256=rPQZ46YiN-PnpY91hDPOFJgZtlAiyIiyVE3P9yvo50o,540
|
81
90
|
atlas_init/tf/modules/cfn/variables.tf,sha256=qbYffl4ly0K8IRTwG3P7-Yyzm5OBTVRZCmDP69WMp44,379
|
82
|
-
atlas_init/tf/modules/cloud_provider/cloud_provider.tf,sha256=
|
91
|
+
atlas_init/tf/modules/cloud_provider/cloud_provider.tf,sha256=aDphNyoR1PLrTpp2TMmetS_LD8SVpgd2YOA2K-5XJtk,1448
|
83
92
|
atlas_init/tf/modules/cloud_provider/provider.tf,sha256=IDpMSLO3GjkxCvF-4qdHugxYq_w-Epujr51HZf_xB0Y,237
|
84
93
|
atlas_init/tf/modules/cluster/cluster.tf,sha256=TId4JsmSDlSHtIzmo3p4GKUVRhzZK9eoiI7DmoYgdq0,3041
|
85
94
|
atlas_init/tf/modules/cluster/provider.tf,sha256=RmUmMzMfOT5LZIWYqxM2EgtkI7JWqZfj3p3TxZkZoLk,161
|
95
|
+
atlas_init/tf/modules/encryption_at_rest/main.tf,sha256=91j1oFiuiBf2wookVVKLwvz43z_qfKLWLZ4ALBy-DAw,566
|
96
|
+
atlas_init/tf/modules/encryption_at_rest/provider.tf,sha256=bTLeeNQjVu9jF_Z7vnY6w9yZP61okCEednMPkS3MLlg,162
|
86
97
|
atlas_init/tf/modules/federated_vars/federated_vars.tf,sha256=YTrvDFCHpxwSeoiCOQRB1GdktH3OxFkUVsFYvLhwG2o,1238
|
87
98
|
atlas_init/tf/modules/federated_vars/provider.tf,sha256=RmUmMzMfOT5LZIWYqxM2EgtkI7JWqZfj3p3TxZkZoLk,161
|
88
99
|
atlas_init/tf/modules/project_extra/project_extra.tf,sha256=YkMFLYuAmWd-Hn3afgN3qhdppRLOEL6sStfEN5dOxcc,1512
|
@@ -91,7 +102,7 @@ atlas_init/tf/modules/vpc_peering/vpc_peering.tf,sha256=hJ3KJdGbLpOQednUpVuiJ0Cq
|
|
91
102
|
atlas_init/tf/modules/vpc_privatelink/atlas-privatelink.tf,sha256=FloaaX1MNDvoMZxBnEopeLKyfIlq6kaX2dmx8WWlXNU,1298
|
92
103
|
atlas_init/tf/modules/vpc_privatelink/variables.tf,sha256=gktHCDYD4rz6CEpLg5aiXcFbugw4L5S2Fqc52QYdJyc,255
|
93
104
|
atlas_init/tf/modules/vpc_privatelink/versions.tf,sha256=G0u5V_Hvvrkux_tqfOY05pA-GzSp_qILpfx1dZaTGDc,237
|
94
|
-
atlas_init-0.4.
|
95
|
-
atlas_init-0.4.
|
96
|
-
atlas_init-0.4.
|
97
|
-
atlas_init-0.4.
|
105
|
+
atlas_init-0.4.2.dist-info/METADATA,sha256=jPqN8mPKb77ojXt7dDWWFk54KhwGxb2hhYWQh7Mv3nc,5741
|
106
|
+
atlas_init-0.4.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
107
|
+
atlas_init-0.4.2.dist-info/entry_points.txt,sha256=oSNFIEAS9nUZyyZ8Fc-0F0U5j-NErygy01LpJVSHapQ,57
|
108
|
+
atlas_init-0.4.2.dist-info/RECORD,,
|
@@ -1,31 +0,0 @@
|
|
1
|
-
from collections import Counter
|
2
|
-
|
3
|
-
from github.WorkflowJob import WorkflowJob
|
4
|
-
from zero_3rdparty import datetime_utils
|
5
|
-
|
6
|
-
from atlas_init.cli_tf.go_test_run import GoTestRun, GoTestStatus
|
7
|
-
|
8
|
-
|
9
|
-
def format_job(job: WorkflowJob) -> str:
|
10
|
-
date = datetime_utils.date_filename(job.created_at)
|
11
|
-
exec_time = "0s"
|
12
|
-
if complete_ts := job.completed_at:
|
13
|
-
exec_time = f"{(complete_ts - job.created_at).total_seconds()}s"
|
14
|
-
return f"{date}_{job.workflow_name}_attempt{job.run_attempt}_ ({exec_time})"
|
15
|
-
|
16
|
-
|
17
|
-
def job_summary(runs: list[GoTestRun]) -> tuple[WorkflowJob, str]:
|
18
|
-
status_counts: dict[GoTestStatus, int] = Counter()
|
19
|
-
for run in runs:
|
20
|
-
status_counts[run.status] += 1
|
21
|
-
line = [f"{key}={status_counts[key]}" for key in sorted(status_counts.keys())]
|
22
|
-
job = runs[0].job
|
23
|
-
return job, f"{format_job(job)}:" + ",".join(line)
|
24
|
-
|
25
|
-
|
26
|
-
def fail_test_summary(runs: list[GoTestRun]) -> str:
|
27
|
-
failed_runs = [r for r in runs if r.is_failure]
|
28
|
-
failed_details: list[str] = [run.finish_summary() for run in failed_runs]
|
29
|
-
failed_names = [f"- {run.name}" for run in failed_runs]
|
30
|
-
delimiter = "\n" + "-" * 40 + "\n"
|
31
|
-
return "\n".join(failed_details) + delimiter + "\n".join(failed_names)
|
File without changes
|
File without changes
|