| Hi Laura Fitzgerald, The App is one CR as the Database is another. Note that each CR means one type of resource. This project was developed following exactly the instructions of the Getting Started and the operator-framework doc as the documentation provided in the training that the team attend over this subject. Note that the way that it is now with one type for the DB and another for the APP we are following the same approach of Prometheus for example which I understand that it is doing as it is recommended to get done. The Prometheus has one type/ CR for each thing. See here <https://github.com/coreos/prometheus-operator>. If you check in the docs and in the examples you will see that all operators following this idea/approach that we are doing here and not just Prometheus which definitely is a great example. This one has the service and database as us:
This one is from AWS in HELM and has one CR for each thing as well ( DynamoDB, ECRRepository and etc .. )
Please, feel free to check the operators available in https://operatorhub.io/ to validate this approach as its documents. Also, if we create a CR for all it will not be a good approach at all for many reasons as for example:
- We will define that the type MSS is the project + database, for me conceptual it not make sense.
- The way that it is now we can just not install the type DB and use a community operator if we wish
- The wat that is now we can easily extract the DB and create a new operator just for it
- if we would like to remove the DB from the project then it is very very easy since is very clear what should be removed or not when we have a specific type for each thing.
In order to attend the need and make the things easier for the users and us we impl the make commands. By the make commands you can, for example, run `make create-all` and it will create the namespace, apply the CRs, the roles and the service account. Also, we can just do the required impl to make our project available in the operatorHub as well which will allow the users to install our product by click and a beautiful interface. See the PR: <https://github.com/aerogear/mobile-security-service-operator/pull/15> It is already doing it, just need some changes/fixes to get done. I hope that this info clarifies the reasons for it got done in this way and allow us to close this task. c/c David Ffrench @chfoley@redhat.com |