Skip to content

Commit

Permalink
Fix SO CEL expression and migrate index Dockerfile
Browse files Browse the repository at this point in the history
Signed-off-by: Pierangelo Di Pilato <[email protected]>
  • Loading branch information
pierDipi committed Oct 8, 2024
1 parent ac8d2e4 commit ec230da
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 12 deletions.
2 changes: 1 addition & 1 deletion config/serverless-operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ repositories:
- serving/metadata-webhook/.*
- serving/ingress/.*
- olm-catalog/serverless-operator/Dockerfile
- olm-catalog/serverless-operator/index/Dockerfile
- olm-catalog/serverless-operator-index/Dockerfile
e2e:
- match: ^operator-e2e$
- match: ^test-upgrade$
Expand Down
20 changes: 9 additions & 11 deletions pkg/prowgen/prowgen_konflux.go
Original file line number Diff line number Diff line change
Expand Up @@ -275,20 +275,18 @@ func GenerateKonfluxServerlessOperator(ctx context.Context, openshiftRelease Rep
},
AdditionalTektonCELExpressionFunc: func(cfg cioperatorapi.ReleaseBuildConfiguration, ib cioperatorapi.ProjectDirectoryImageBuildStepConfiguration) string {
if string(ib.To) == "serverless-index" {
return "&& ( " +
"files.all.exists(x, x.matches('^olm-catalog/serverless-operator/index/') ||" +
"files.all.exists(x, x.matches('^.tekton/.*serverless-index.*') " +
")"
return " && (" +
" files.all.exists(x, x.matches('^olm-catalog/serverless-operator-index/')) ||" +
" files.all.exists(x, x.matches('^.tekton/'))" +
" )"
}
if string(ib.To) == "serverless-bundle" {
return "&& ( " +
"files.all.exists(x, x.matches('^olm-catalog/serverless-operator/manifests/')) || " +
"files.all.exists(x, x.matches('^olm-catalog/serverless-operator/metadata/')) || " +
"files.all.exists(x, x.matches('^olm-catalog/serverless-operator/Dockerfile')) ||" +
"files.all.exists(x, x.matches('^.tekton/.*serverless-bundle.*') " +
")"
return " && (" +
" files.all.exists(x, x.matches('^olm-catalog/serverless-operator/')) ||" +
" files.all.exists(x, x.matches('^.tekton/'))" +
" )"
}
nonCatalog := "&& files.all.exists(x, !x.matches('^olm-catalog/'))"
nonCatalog := " && files.all.exists(x, !x.matches('^olm-catalog/'))"
return nonCatalog
},
Includes: []string{
Expand Down

0 comments on commit ec230da

Please sign in to comment.