This is a first PR for a major refactoring of DCR monitor. See #15
[!WARNING]
This PR breaks attestation functionality, because TEEProvider does not implement attestation feature yet.
Changes
Change Monitor to be a "Reconciler", which runs a reconciliation loop every 10 seconds. This required me to change k8s CronJob to Deployment, and have reconciliation loop in the app (cronjob only supports > 1 minute)
Create TEEProvider type to support different TEE backends. Only partially implemented right now.
Clean up unused functions (ListAllInstances, DeleteInstance)
Added a unit test for reconcileJob function
Added the bazel test //... to the CI
Testing
Manually deployed & tested. Also added a unit test for updateJobStatus
didn't test Reconcile, it needs dependency injection for the DB.
This is a first PR for a major refactoring of DCR monitor. See #15
Changes
CronJob
toDeployment
, and have reconciliation loop in the app (cronjob only supports > 1 minute)TEEProvider
type to support different TEE backends. Only partially implemented right now.ListAllInstances
,DeleteInstance
)reconcileJob
functionbazel test //...
to the CITesting
Manually deployed & tested. Also added a unit test for
updateJobStatus
didn't testReconcile
, it needs dependency injection for the DB.