Closed rivernews closed 4 years ago
This is indeed a common problem. Wildcard certificate, different namespace. How?
This isn’t probably a good start: https://scriptthe.net/2019/06/21/utilize-a-default-certificate-for-services-fronted-by-nginx-ingress/
[x] Migrate appl tracky
[x] Migrate slack
[x] Migrate postgres cluster to its own namespace
kubernetes_ingress
and kubernetes_service_account
.psql -U admin default_database
and drop database <name>;
then create database <name>
.[x] Migrate redis cluster to its own namespace
[x] Can we remove the iriversland2 block in ingress controller? To do a complete de-coupling.
[x] Can we change microservice module's ingress tf name from project-*
to app
?
[x] Lastly, we want to de-couple the installation tf module out of this repo. But let's make sure the above is done first.
How should we approach this?
Imagine what the result should be like
Resolved K8 unauthorized error, see code comment in k8 provider block. Deployed module caller in each microservices repository.
Currently we are using one namespace for all microservices (specified a fixed namespace in our custom terraform module). It would be great if we can separate them into different microservices.
The challenge is we are using a single wildcard certificate that intends to serve all ingress of every microservices:
If we are using different namespace for each service, we will end up having several certificates, even if we only have one ClusterIssuer, and should only need one wildcard certificate that covers all domains services will deploy to.
Multiple certificate might work as well, it's just a concern if this will cause unnecessary api calls to letsencrypt, since letsencrypt has a pretty strict quota limit. Needs further investigation into this.
Relevant posts
controller.extraArgs.default-ssl-certificate
(also here) on helm_release ing controller. Indeed it's a valid parameter for kubernetes nginx ingress. Have to figure out how it work,could be a good start. Be aware that it may only work for hosts that do not match any ing rule, so might not work for our case, where we want to use the certificate for all ing hosts.default-ssl-certificate
.