Skip to content

Commit 152ba82

Browse files
Use generator synced config for FargateProfile (#30)
1 parent f0e8144 commit 152ba82

File tree

7 files changed

+17
-31
lines changed

7 files changed

+17
-31
lines changed
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
ack_generate_info:
2-
build_date: "2022-03-01T23:22:01Z"
2+
build_date: "2022-03-02T18:17:17Z"
33
build_hash: 7dff1f4590e623d17e58660b7dd1c66e22b5215a
44
go_version: go1.17.1
55
version: v0.17.1
66
api_directory_checksum: 50ce02741686341685d2a897fdcdd80c80e260d9
77
api_version: v1alpha1
88
aws_sdk_go_version: v1.42.0
99
generator_config_info:
10-
file_checksum: d001fb15bd0b8f654bfaa80e0762814216d374b8
10+
file_checksum: 56a08a2624b3ec00e907af51f8d77f3d80337eee
1111
original_file_name: generator.yaml
1212
last_modification:
1313
reason: API generation

apis/v1alpha1/generator.yaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,12 +99,15 @@ resources:
9999
hooks:
100100
delta_pre_compare:
101101
code: customPreCompare(a, b)
102-
sdk_read_one_post_set_output:
103-
template_path: hooks/fargate_profile/sdk_read_one_post_set_output.go.tpl
104102
sdk_delete_pre_build_request:
105103
template_path: hooks/fargate_profile/sdk_delete_pre_build_request.go.tpl
106104
update_operation:
107105
custom_method_name: customUpdate
106+
synced:
107+
when:
108+
- path: Status.Status
109+
in:
110+
- ACTIVE
108111
Nodegroup:
109112
fields:
110113
ClusterName:

generator.yaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,12 +99,15 @@ resources:
9999
hooks:
100100
delta_pre_compare:
101101
code: customPreCompare(a, b)
102-
sdk_read_one_post_set_output:
103-
template_path: hooks/fargate_profile/sdk_read_one_post_set_output.go.tpl
104102
sdk_delete_pre_build_request:
105103
template_path: hooks/fargate_profile/sdk_delete_pre_build_request.go.tpl
106104
update_operation:
107105
custom_method_name: customUpdate
106+
synced:
107+
when:
108+
- path: Status.Status
109+
in:
110+
- ACTIVE
108111
Nodegroup:
109112
fields:
110113
ClusterName:

pkg/resource/fargate_profile/hook.go

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,6 @@ var (
3838
)
3939
)
4040

41-
// profileActive returns true if the supplied EKS FargateProfile is in the
42-
// `Active` status
43-
func profileActive(r *resource) bool {
44-
if r.ko.Status.Status == nil {
45-
return false
46-
}
47-
ps := *r.ko.Status.Status
48-
return ps == svcsdk.FargateProfileStatusActive
49-
}
50-
5141
// profileDeleting returns true if the supplied EKS FargateProfile is in the
5242
// `Deleting` status
5343
func profileDeleting(r *resource) bool {

pkg/resource/fargate_profile/manager.go

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/resource/fargate_profile/sdk.go

Lines changed: 0 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

templates/hooks/fargate_profile/sdk_read_one_post_set_output.go.tpl

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)