Azure / ARO-RP

Azure Red Hat OpenShift RP
https://azure.microsoft.com/products/openshift/
Apache License 2.0
101 stars 170 forks source link

ARO_IMAGE is mandatory now #925

Open mjudeikis opened 4 years ago

mjudeikis commented 4 years ago

As a developer, I don't want to care if ARO_IMAGE is set or not if I'm not working on that part of the code. We should have sane defaults. Currently, after operator merged it is required for devs to set ARO_IMAGE for aro rp to work.

the suggestion was to use:


func (d *dev) AROOperatorImage() string {
    override := os.Getenv("ARO_IMAGE")
        tag := vesiong.GitCommit 
    if override != "" {
        return override
    }
        # in case we running on dirty code without override:
        if tag == "unknown"{
             tag = "master"
        }
    return fmt.Sprintf("%s.azurecr.io/aro:%s", d.acrName, tag)
}

For discussion @asalkeld @jim-minter @ehashman

asalkeld commented 4 years ago

so, we have ARO_IMAGE in env.example, I think this is not a big hassle - it's just a once off change..

asalkeld commented 4 years ago

one option would be to add it to env/secrets - assuming that is purely for developers and not used in CI or any other context

mjudeikis commented 4 years ago

My question is why we cant decide it dynamically if override is not set? What is stopping factor here?