-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* make catalog server serve catalog contents over HTTPS adds cert-manager as a dependency again to create self-signed certs for the catalog server Signed-off-by: everettraven <everettraven@gmail.com> * fix e2e Signed-off-by: everettraven <everettraven@gmail.com> * Reorganize manifests for cert-manager overlay This allows the use of alternate certificate managers. Signed-off-by: Tayler Geiger <tayler@redhat.com> * Reconfigure TLS functionality to use Listener Fix a few manifest issues as well. Signed-off-by: Tayler Geiger <tayler@redhat.com> * Add certwatcher for TLS cert and key from controller-runtime - Add error for missing either tls-key or tls-cert arguments. - Move server creation and configuration to serverutil Signed-off-by: Tayler Geiger <tayler@redhat.com> * Update README and docs for HTTPS --------- Signed-off-by: everettraven <everettraven@gmail.com> Signed-off-by: Tayler Geiger <tayler@redhat.com> Co-authored-by: everettraven <everettraven@gmail.com>
- Loading branch information
1 parent
250e348
commit cf384e4
Showing
35 changed files
with
303 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,4 +15,3 @@ resources: | |
- ../crd | ||
- ../rbac | ||
- ../manager | ||
|
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
--- | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: ClusterRole | ||
metadata: | ||
name: manager-role | ||
rules: | ||
- apiGroups: | ||
- catalogd.operatorframework.io | ||
resources: | ||
- catalogs | ||
verbs: | ||
- create | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- update | ||
- watch | ||
- apiGroups: | ||
- catalogd.operatorframework.io | ||
resources: | ||
- catalogs/finalizers | ||
verbs: | ||
- update | ||
- apiGroups: | ||
- catalogd.operatorframework.io | ||
resources: | ||
- catalogs/status | ||
verbs: | ||
- get | ||
- patch | ||
- update | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- pods | ||
verbs: | ||
- create | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- update | ||
- watch | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- pods/log | ||
verbs: | ||
- get | ||
- list | ||
- watch | ||
--- | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: Role | ||
metadata: | ||
name: manager-role | ||
namespace: system | ||
rules: | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- secrets | ||
verbs: | ||
- get |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Adds namespace to all resources. | ||
namespace: catalogd-system | ||
|
||
# Value of this field is prepended to the | ||
# names of all resources, e.g. a deployment named | ||
# "wordpress" becomes "alices-wordpress". | ||
# Note that it should also match with the prefix (text before '-') of the namespace | ||
# field above. | ||
namePrefix: catalogd- | ||
|
||
# the following config is for teaching kustomize how to do var substitution | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
resources: | ||
- ../../base/crd | ||
- ../../base/rbac | ||
- ../../base/manager | ||
- resources | ||
|
||
patches: | ||
- target: | ||
kind: Service | ||
name: catalogserver | ||
path: patches/catalogserver_service_port.yaml | ||
- target: | ||
kind: Deployment | ||
name: controller-manager | ||
path: patches/manager_deployment_certs.yaml |
6 changes: 6 additions & 0 deletions
6
config/overlays/cert-manager/patches/catalogserver_service_port.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
- op: replace | ||
path: /spec/ports/0/port | ||
value: 443 | ||
- op: replace | ||
path: /spec/ports/0/name | ||
value: https |
12 changes: 12 additions & 0 deletions
12
config/overlays/cert-manager/patches/manager_deployment_certs.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
- op: add | ||
path: /spec/template/spec/volumes/- | ||
value: {"name":"catalogserver-certs", "secret":{"secretName":"catalogd-catalogserver-cert"}} | ||
- op: add | ||
path: /spec/template/spec/containers/1/volumeMounts/- | ||
value: {"name":"catalogserver-certs", "mountPath":"/var/certs"} | ||
- op: add | ||
path: /spec/template/spec/containers/1/args/- | ||
value: "--tls-cert=/var/certs/tls.crt" | ||
- op: add | ||
path: /spec/template/spec/containers/1/args/- | ||
value: "--tls-key=/var/certs/tls.key" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
apiVersion: cert-manager.io/v1 | ||
kind: Certificate | ||
metadata: | ||
name: catalogserver-cert | ||
namespace: system | ||
spec: | ||
secretName: catalogd-catalogserver-cert | ||
dnsNames: | ||
- localhost | ||
- catalogd-catalogserver.catalogd-system.svc | ||
issuerRef: | ||
kind: Issuer | ||
name: catalogd-catalogserver-ca-issuer |
Oops, something went wrong.