Skip to content

Commit 44ed64e

Browse files
authored
Merge pull request #324 from p-strusiewiczsurmacki-mobica/cert-enable-fix
Fixed enable-certs-rotation makefile target
2 parents 9fc8ce5 + 41d4483 commit 44ed64e

File tree

7 files changed

+31
-12
lines changed

7 files changed

+31
-12
lines changed

v2/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -301,8 +301,8 @@ endef
301301
.PHONY: enable-certs-rotation
302302
enable-certs-rotation:
303303
@sed -i "9,21 {s/^# //}" kustomization.yaml
304-
@sed -i -E 's/^(- coil-.*controller_role\.yaml)/# \1/g' ../config/rbac/kustomization.yaml
305-
@sed -i -E 's/^# (- coil-.*controller-certs_role\.yaml)/\1/g' ../config/rbac/kustomization.yaml
304+
@sed -i -E 's/^(- coil-.*controller_role\.yaml)/# \1/g' config/rbac/kustomization.yaml
305+
@sed -i -E 's/^# (- coil-.*controller-certs_role\.yaml)/\1/g' config/rbac/kustomization.yaml
306306
@touch config/default/cert.pem
307307
@touch config/default/ipam-cert.pem
308308
@touch config/default/ipam-key.pem

v2/config/default/egress/v6/kustomization.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@ secretGenerator:
1919
- ca.crt=../../cert.pem
2020
- tls.crt=../../egress-cert.pem
2121
- tls.key=../../egress-key.pem
22-
type: "kubernetes.io/tls"
22+
type: "kubernetes.io/tls"

v2/config/default/kustomization.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ secretGenerator:
2929
- ca.crt=./cert.pem
3030
- tls.crt=./egress-cert.pem
3131
- tls.key=./egress-key.pem
32-
type: "kubernetes.io/tls"
32+
type: "kubernetes.io/tls"

v2/config/rbac/egress/kustomization.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ resources:
55
- ../leader_election_role_binding.yaml
66
- ../coild_role.yaml
77
# [EGRESS] Following files should be uncommented to enable Egress NAT features.
8+
# [CERTS] Please uncomment 'coil-egress-controller-certs_role.yaml' and
9+
# comment 'coil-egress-controller_role.yaml' if automatic cert generation is being used.
810
- ../coil-egress-controller_role.yaml
11+
# - ../coil-egress-controller-certs_role.yaml
912
- ../coil-egress_role.yaml
1013
- ../egress_viewer_role.yaml

v2/e2e/Makefile

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -81,14 +81,6 @@ TEST_EGRESS ?= true
8181
test: setup-echotest
8282
TEST_IPAM=$(TEST_IPAM) TEST_EGRESS=$(TEST_EGRESS) go test -count 1 -v . -args -ginkgo.progress -ginkgo.v
8383

84-
.PHONY: test-ipam
85-
test-ipam: setup-echotest
86-
TEST_IPAM=$(TEST_IPAM) TEST_EGRESS=$(TEST_EGRESS) go test -count 1 -v . -args -ginkgo.progress -ginkgo.v
87-
88-
.PHONY: test-egress
89-
test-egress: setup-echotest
90-
TEST_IPAM=$(TEST_IPAM) TEST_EGRESS=$(TEST_EGRESS) go test -count 1 -v . -args -ginkgo.progress -ginkgo.v
91-
9284
.PHONY: setup-echotest
9385
setup-echotest:
9486
CGO_ENABLED=0 go build -o echotest ./echo-server
@@ -111,8 +103,12 @@ endef
111103
.PHONY: enable-certs-rotation
112104
enable-certs-rotation:
113105
@sed -i "9,21 {s/^# //}" kustomization.yaml
106+
@sed -i "18,24 {s/^# //}" configs/egress/v4/kustomization.yaml
107+
@sed -i "18,24 {s/^# //}" configs/egress/v6/kustomization.yaml
114108
@sed -i -E 's/^(- coil-.*controller_role\.yaml)/# \1/g' ../config/rbac/kustomization.yaml
115109
@sed -i -E 's/^# (- coil-.*controller-certs_role\.yaml)/\1/g' ../config/rbac/kustomization.yaml
110+
@sed -i -E 's/^(- \.\.\/coil-.*controller_role\.yaml)/# \1/g' ../config/rbac/egress/kustomization.yaml
111+
@sed -i -E 's/^# (- \.\.\/coil-.*controller-certs_role\.yaml)/\1/g' ../config/rbac/egress/kustomization.yaml
116112
@touch ../config/default/cert.pem
117113
@touch ../config/default/ipam-cert.pem
118114
@touch ../config/default/ipam-key.pem

v2/e2e/configs/egress/v4/kustomization.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,13 @@ namespace: kube-system
1313
# Labels to add to all resources and selectors.
1414
commonLabels:
1515
app.kubernetes.io/name: coil
16+
17+
# [CERTS] Following patches should be uncommented if automatic cert generation is used.
18+
# patches:
19+
# - path: ../../../../config/pod/generate_certs.yaml
20+
# target:
21+
# group: apps
22+
# version: v1
23+
# kind: Deployment
24+
# name: coil-egress-controller
25+

v2/e2e/configs/egress/v6/kustomization.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,13 @@ namespace: kube-system
1313
# Labels to add to all resources and selectors.
1414
commonLabels:
1515
app.kubernetes.io/name: coil
16+
17+
# [CERTS] Following patches should be uncommented if automatic cert generation is used.
18+
# patches:
19+
# - path: ../../../../config/pod/generate_certs.yaml
20+
# target:
21+
# group: apps
22+
# version: v1
23+
# kind: Deployment
24+
# name: coil-egress-controller
25+

0 commit comments

Comments
 (0)