Skip to content

Commit 1aee207

Browse files
refactor: replace dockerhub images for public.ecr.aws (#61)
* refactor: replace dockerhub images for public.ecr.aws * fix: remove depends_on to prevent destroying the actual policy * fix: prevent race condition to deploy zoombie runner cleanup
1 parent 1ef0b9c commit 1aee207

File tree

4 files changed

+26
-7
lines changed

4 files changed

+26
-7
lines changed

modules/core/arc/scale_set/template_files/dind.yml.tftpl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ template:
3737

3838
- name: init-dind-rootless
3939
imagePullPolicy: Always
40-
image: docker:dind-rootless
40+
image: public.ecr.aws/docker/library/docker:dind-rootless
4141
command:
4242
- sh
4343
- -c
@@ -127,7 +127,7 @@ template:
127127
memory: ${container_requests_memory}
128128

129129
- name: dind
130-
image: docker:dind-rootless
130+
image: public.ecr.aws/docker/library/docker:dind-rootless
131131
imagePullPolicy: Always
132132
args: ["dockerd", "--host=unix:///home/runner/var/run/docker.sock"]
133133
securityContext:
@@ -157,7 +157,7 @@ template:
157157
memory: ${container_requests_memory}
158158

159159
- name: runner-logs
160-
image: busybox
160+
image: public.ecr.aws/docker/library/busybox:stable
161161
command:
162162
- sh
163163
- -c
@@ -184,7 +184,7 @@ template:
184184
memory: "64Mi"
185185
186186
- name: hook
187-
image: busybox
187+
image: public.ecr.aws/docker/library/busybox:stable
188188
command:
189189
- sh
190190
- -c

modules/core/arc/scale_set/template_files/k8s.yml.tftpl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ template:
6969
memory: ${container_requests_memory}
7070

7171
- name: runner-logs
72-
image: busybox
72+
image: public.ecr.aws/docker/library/busybox:stable
7373
command:
7474
- sh
7575
- -c
@@ -96,7 +96,7 @@ template:
9696
memory: "64Mi"
9797
9898
- name: hook
99-
image: busybox
99+
image: public.ecr.aws/docker/library/busybox:stable
100100
command:
101101
- sh
102102
- -c

modules/core/arc/zoombie.tf

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@ resource "kubernetes_service_account_v1" "zombie_runner_cleanup" {
44
name = "zombie-runner-cleanup"
55
namespace = var.controller_config.namespace
66
}
7+
8+
depends_on = [
9+
module.controller,
10+
module.scale_sets
11+
]
712
}
813

914
resource "kubernetes_role_v1" "zombie_runner_cleanup" {
@@ -24,6 +29,11 @@ resource "kubernetes_role_v1" "zombie_runner_cleanup" {
2429
resources = ["ephemeralrunners"]
2530
verbs = ["get", "list", "delete", "watch"]
2631
}
32+
33+
depends_on = [
34+
module.controller,
35+
module.scale_sets
36+
]
2737
}
2838

2939
resource "kubernetes_role_binding_v1" "zombie_runner_cleanup" {
@@ -44,6 +54,11 @@ resource "kubernetes_role_binding_v1" "zombie_runner_cleanup" {
4454
kind = "Role"
4555
name = kubernetes_role_v1.zombie_runner_cleanup[0].metadata[0].name
4656
}
57+
58+
depends_on = [
59+
module.controller,
60+
module.scale_sets
61+
]
4762
}
4863

4964
resource "kubernetes_cron_job_v1" "zombie_runner_cleanup" {
@@ -90,4 +105,9 @@ resource "kubernetes_cron_job_v1" "zombie_runner_cleanup" {
90105
}
91106
}
92107
}
108+
109+
depends_on = [
110+
module.controller,
111+
module.scale_sets
112+
]
93113
}

modules/infra/eks/nodes.tf

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,5 @@ module "self_managed_node_group" {
5757

5858
depends_on = [
5959
time_sleep.wait_300_seconds,
60-
null_resource.create_calico_installation
6160
]
6261
}

0 commit comments

Comments
 (0)