BUG get image logic
mateusoliveira43 opened this issue · comments
Description
OADP code is changed when sent to production, for example
oadp-operator/config/manager/manager.yaml
Lines 39 to 56 in fe0444c
values are changed to production images.
But, these values are not changed
oadp-operator/pkg/common/common.go
Lines 60 to 69 in fe0444c
Which means, in a production environment, all fallback from below functions, are wrong.
oadp-operator/controllers/velero.go
Lines 514 to 522 in fe0444c
oadp-operator/pkg/credentials/credentials.go
Lines 94 to 152 in fe0444c
How to reproduce
Install OADP operator from marketplace and change the value of one these environment variables to an empty string (or remove the environment variable). Create DPA that will use one of these images, without using unsupportedOverrides. OADP will try to use a non production image instead of a production one.
Related work for DPA when API version updates
Instead of having unsupportedOverrides field in DPA, could not we use these environment variables to change images used? Instead of a field in DPA, would need to change value in operator CSV.
change the value of one these environment variables to an empty string
well that's not really a supported configuration. but I could see how it can be interpreted as a bug.
@kaovilai is it dangerous somehow to edit that?
Not dangerous but not sure why one would make a change there and set it to empty.
The empty was just to show that there is no need for the fallback value
What I would really like is to remove unsupportedOverrides (in new version of DPA) and change these environment variables instead. It should be as easy as it is to set a value in DPA.
sounds good.
unsupporetedOverrides would remain for non images
Yeah, need to see if there is a easy way to change this as well
oadp-operator/api/v1alpha1/oadp_types.go
Line 65 in fe0444c
Let's not change that, it's for MTC.
Issues go stale after 90d of inactivity.
Mark the issue as fresh by commenting /remove-lifecycle stale
.
Stale issues rot after an additional 30d of inactivity and eventually close.
Exclude this issue from closing by commenting /lifecycle frozen
.
If this issue is safe to close now please do so with /close
.
/lifecycle stale
/lifecycle frozen