Skip to content

Commit 6e1fa6a

Browse files
committed
Reorganize config to support reusable components
Update to catalogd v0.17.0 to share a common certificate issuer Signed-off-by: Todd Short <[email protected]>
1 parent ceba614 commit 6e1fa6a

20 files changed

+111
-106
lines changed

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ else
5454
$(warning Could not find docker or podman in path! This may result in targets requiring a container runtime failing!)
5555
endif
5656

57-
KUSTOMIZE_BUILD_DIR := config/overlays/tls
57+
KUSTOMIZE_BUILD_DIR := config/overlays/cert-manager
5858

5959
# Disable -j flag for make
6060
.NOTPARALLEL:
@@ -155,6 +155,7 @@ test-e2e: GO_BUILD_FLAGS := -cover
155155
test-e2e: run image-registry build-push-e2e-catalog registry-load-bundles e2e e2e-coverage kind-clean #HELP Run e2e test suite on local kind cluster
156156

157157
.PHONY: extension-developer-e2e
158+
extension-developer-e2e: KUSTOMIZE_BUILD_DIR := config/overlays/cert-manager
158159
extension-developer-e2e: KIND_CLUSTER_NAME := operator-controller-ext-dev-e2e #EXHELP Run extension-developer e2e on local kind cluster
159160
extension-developer-e2e: run image-registry test-ext-dev-e2e kind-clean
160161

Tiltfile

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,21 @@
11
if not os.path.exists('../tilt-support'):
22
fail('Please clone https://github.com/operator-framework/tilt-support to ../tilt-support')
33

4-
load('../tilt-support/Tiltfile', 'deploy_repo', 'process_yaml')
4+
load('../tilt-support/Tiltfile', 'deploy_repo')
55

66
config.define_string_list('repos', args=True)
77
cfg = config.parse()
88
repos = cfg.get('repos', ['operator-controller', 'catalogd'])
99

1010
repo = {
1111
'image': 'quay.io/operator-framework/operator-controller',
12-
'yaml': 'config/overlays/tls',
12+
'yaml': 'config/secure',
1313
'binaries': {
1414
'manager': 'operator-controller-controller-manager',
1515
},
1616
'starting_debug_port': 30000,
1717
}
1818

19-
process_yaml("testdata/certs/issuers.yaml")
20-
2119
for r in repos:
2220
if r == 'operator-controller':
2321
deploy_repo('operator-controller', repo)

config/README.md

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# OPERATOR-CONTROLLER CONFIG
2+
3+
## config/base
4+
5+
This provides an insecure (i.e. no TLS) basic configuration of operator-controller.
6+
7+
This configuration specifies a namespace of `olmv1-system`.
8+
9+
## config/overlays/cert-manager
10+
11+
This includes support for a secure (i.e. with TLS) configuration of operator-controller. This configuration uses:
12+
* config/base
13+
* config/components/tls
14+
* config/components/ca
15+
16+
This configuration requires cert-manager.
17+
18+
## config/overlays/e2e
19+
20+
This provides additional configuration support for end-to-end testing, including code coverage. This configuration uses:
21+
* config/base
22+
* config/components/tls
23+
* config/components/ca
24+
* config/components/coverage
25+
26+
This configuration requires cert-manager.
27+
28+
## Components
29+
30+
Each of the `kustomization.yaml` files specify a `Component`, rather than an overlay.
31+
32+
### config/components/tls
33+
34+
This provides a basic configuration of operator-controller with TLS support for catalogd.
35+
36+
This component specifies the `olmv1-system` namespace.
37+
38+
This component requires cert-manager.
39+
40+
### config/components/coverage
41+
42+
Provides configuration for code coverage.
43+
44+
This component specifies the `olmv1-system` namespace.
45+
46+
### config/components/ca
47+
48+
Procides a CA for operator-controller operation.
49+
50+
This component _does not_ specify a namespace, and must be included last.
51+
52+
This component requires cert-manager.
File renamed without changes.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
apiVersion: kustomize.config.k8s.io/v1alpha1
2+
kind: Component
3+
# No namespace is specified here, otherwise, it will overwrite _all_ the other namespaces!
4+
resources:
5+
- issuers.yaml
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
apiVersion: kustomize.config.k8s.io/v1alpha1
2+
kind: Component
3+
namespace: olmv1-system
4+
resources:
5+
- manager_e2e_coverage_pvc.yaml
6+
- manager_e2e_coverage_copy_pod.yaml
7+
patches:
8+
- path: manager_e2e_coverage_patch.yaml
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
apiVersion: kustomize.config.k8s.io/v1alpha1
2+
kind: Component
3+
namespace: olmv1-system
4+
resources:
5+
- resources/manager_cert.yaml
6+
patches:
7+
- target:
8+
kind: Deployment
9+
name: controller-manager
10+
path: patches/manager_deployment_cert.yaml

0 commit comments

Comments
 (0)