Skip to content

OPRUN-2913: Sync api, operator-registry, operator-lifecycle-manager downstream #510

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 105 commits into from
Jul 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
105 commits
Select commit Hold shift + click to select a range
585780b
Update sync script
tmshort Jun 29, 2023
1b71d6b
fix(openshift): use env var instead of clusterversion status (#2817)
tylerslaton Aug 2, 2022
3aab5ed
deprecate io/ioutil for io or os (#2835)
grokspawn Aug 9, 2022
2599ca6
add grokspawn to OWNERS (#2833)
grokspawn Aug 9, 2022
a2213d7
Fixes doc error: namespace name must have changed (#2839)
bentito Aug 18, 2022
e107341
opm serve: use pre-existing cache, if set and up-to-date (#1005)
joelanford Aug 19, 2022
ecc922f
Fix a panic when reading annotations if the bundle is not there (#255)
bcrochet Aug 23, 2022
ae40092
introduce spec.runAsRoot field (#258)
grokspawn Aug 26, 2022
67a0d92
chore: update o-f/api dependency to v0.17 (#2848)
tylerslaton Aug 31, 2022
0e821b4
Revert "chore: update o-f/api dependency to v0.17 (#2848)" (#2858)
anik120 Sep 13, 2022
666edcf
bump k8s to 1.25 and go to 1.19 (#260)
laxmikantbpandhare Sep 15, 2022
a6c254c
Updating workflows to pull go version from go.mod file (#1025)
grokspawn Sep 23, 2022
1f97958
bump k8s to 1.25 (#1024)
asmacdo Sep 26, 2022
955e883
Makefile: Remove the -v go mod tidy flag to fix the verify check (#262)
timflannagan Sep 29, 2022
02cdace
go.*,pkg: Remove the duplicate github.com/blang/semver dependency (#264)
timflannagan Sep 29, 2022
0395921
crds,Makefile: Bump controller-tools version to v0.9.0 (#263)
timflannagan Sep 29, 2022
7fb9110
(makefile) Upgrade mikefarah/yq to v4 (#267)
anik120 Oct 6, 2022
7617e9d
(makefile) Dynamically set GOARCH flag while building binaries (#2871)
anik120 Oct 12, 2022
13b851a
go upgrade to 1.19 (#1029)
jcho02 Oct 19, 2022
78bba08
update k8s 1.25 validation logic (#270)
everettraven Oct 28, 2022
dea3ad0
Update OWNERS file (#2882)
awgreene Nov 7, 2022
997faf6
Allow E2E to skip multiple tests (#2892)
awgreene Nov 11, 2022
97a7d30
Revert "Allow E2E to skip multiple tests (#2892)" (#2894)
awgreene Nov 14, 2022
7928921
left-right swap edge vertices (#1041)
grokspawn Nov 15, 2022
f3c6f0b
semver veneer: error when unknown fields are encountered in input fil…
joelanford Nov 22, 2022
828090d
OWNERS: Remove timflannagan as reviewer/approver (#2899)
timflannagan Nov 30, 2022
cc75ec2
adding grokspawn to tide owners file (#268)
grokspawn Nov 30, 2022
8a9288a
Bump github.com/containerd/containerd to 1.6.10 (#2903)
cblecker Dec 5, 2022
e8efb42
Fix flaky unit tests (#2904)
cblecker Dec 6, 2022
7afbb80
(bugfix): make k8s 1.25 validation logic check api group before issui…
everettraven Dec 21, 2022
91dfcf6
Run community catalogSource in restricted mode (#2915)
awgreene Jan 12, 2023
7721977
opm migrate: add help text note about concatenated json format (#1055)
joelanford Jan 20, 2023
c4bc43d
Don't use $BUILDPLATFORM image for goreleaser (#2896)
StopMotionCuber Jan 27, 2023
4ed10b6
Bump Fedora Version for Builder Image (#2921)
dtfranz Feb 9, 2023
904150c
Bump k8s to 1.26
rashmigottipati Feb 23, 2023
610dfbb
build(deps): bump golang.org/x/text from 0.3.7 to 0.3.8
dependabot[bot] Feb 23, 2023
0bad859
Bump golang.org/x/text from 0.3.7 to 0.3.8 (#2926)
dependabot[bot] Feb 28, 2023
825bfd9
Bump golang.org/x/net from 0.0.0-20220909164309-bea034e7d591 to 0.7.0…
dependabot[bot] Feb 28, 2023
aa39c3e
Bump github.com/containerd/containerd from 1.6.10 to 1.6.18 (#2922)
dependabot[bot] Feb 28, 2023
287fea9
Bump helm.sh/helm/v3 from 3.9.0 to 3.10.3 (#2930)
perdasilva Feb 28, 2023
2152d39
Bump k8s dependencies to 1.26.1 (#1072)
rashmigottipati Mar 3, 2023
9688f9b
bump golang.org/x/net from 0.4.0 to 0.7.0 (#1064)
dependabot[bot] Mar 3, 2023
d277cde
Remove grace period from csv deletions (#2580)
perdasilva Mar 7, 2023
5da0904
opm render: update help text to mention that output is a stream to st…
joelanford Mar 7, 2023
62a8fe8
Makes golangci-lint use Go version from go.mod (#2935)
m1kola Mar 8, 2023
f68e16d
Add QMEU to goreleaser GitHub Action (#2936)
awgreene Mar 14, 2023
9712321
Add affinity customization to catalog source grpc pods
Jamstah Mar 5, 2023
f5eca69
Helm upgrade to v3.11.1 for CVE-2023-25165 (#2933)
tmshort Mar 14, 2023
86a7ca2
Registry Pod Controller Flag (#2928)
dtfranz Mar 15, 2023
92e38a5
Updates `syncResolvingNamespace` tests
Mar 24, 2023
0a20493
Add Support for Fetching Remote Catalog (#1079)
Mar 28, 2023
051cd76
Improve ClusterServiceVersion schema. (#168)
TheRealJon Mar 28, 2023
fa98c99
Package sort for deterministic ordering in ListBundles API (#1084)
grokspawn Apr 3, 2023
1585161
build(deps): bump github.com/containerd/containerd from 1.5.13 to 1.5…
dependabot[bot] Apr 6, 2023
8877148
take image domain name from env (#791)
akihikokuroda Apr 6, 2023
4760e47
Update multi-arch validator to check node affinity for multi-platform…
jaypoulz Apr 10, 2023
1633382
Fixes echo of the current cluster name
Mar 8, 2023
68c63b0
Bump github.com/docker/docker (#2948)
dependabot[bot] Apr 12, 2023
6a76f30
Remove extra jobLabel (#2951)
perdasilva Apr 12, 2023
b096481
Fixes godoc rendering (#2937)
m1kola Apr 12, 2023
c30ed31
Change opm image from `quay.io/operator-framework/upstream-opm-builde…
StopMotionCuber Apr 13, 2023
d8ce125
New condition types (#282)
m1kola Apr 13, 2023
da77ad6
Fix example string for svg icon types (#2953)
perdasilva Apr 14, 2023
3db9ebf
Workaround server-side apply not working (#2911)
sathieu Apr 14, 2023
49b1fd7
Remove vendor dir (#1085)
dtfranz Apr 20, 2023
7adce8b
GitHub Actions Updates (#2956)
dtfranz Apr 24, 2023
73c5ba2
Add linux node selector to bundleUnpacker job (#2685)
aimichelle Apr 24, 2023
f82e39f
Moves bundle unpack timeout into OperatorGroup (#2952)
m1kola Apr 24, 2023
2a6860a
Restores openapi-gen tag for APIResourceReference (#283)
m1kola Apr 25, 2023
ba9790f
refactor to move more processing to the API (#1082)
grokspawn Apr 25, 2023
a61a06a
Updates github.com/operator-framework/api (#2954)
m1kola Apr 26, 2023
f51e2bf
comment out CatalogDestination.BaseImage while we mature the concept …
grokspawn Apr 26, 2023
5a9239b
Add WalkMetas* functions and meta.Name field (#1089)
joelanford May 5, 2023
7855cb1
resolve channel collisions by a preferred channel type, where they ar…
grokspawn May 22, 2023
b4f509b
Bump github.com/docker/distribution (#2966)
dependabot[bot] May 22, 2023
ae0949f
Cleans up the TODO related to `BundleLookupFailed` (#2959)
m1kola May 22, 2023
e674bc2
Prevent OLM from creating `InstallPlan`s when bundle unpack fails (#2…
m1kola May 26, 2023
17ee584
render: improve olm.bundle.object rendering for bundles (#1094)
joelanford Jun 6, 2023
07a9425
bump golang-migrate to v4.16.1 (#1107)
grokspawn Jun 6, 2023
4592bd8
declcfg/load: improvements (#1106)
stevekuznetsov Jun 6, 2023
e2c649d
re-introduce and fix declcfg.Meta unmarshal error (#1109)
joelanford Jun 9, 2023
e543525
Removes error silencing from IsFailForwardEnabled (#2957)
m1kola Jun 12, 2023
948ba2b
updating dependencies (#284)
acornett21 Jun 26, 2023
a4d614d
Updates GH Actions to avoid using deprecated node (#1117)
m1kola Jun 26, 2023
ddeea4c
Switches to codecov GH action (#1118)
m1kola Jun 27, 2023
ab9e089
Bump k8s.io/client-go from v0.26.1 to v0.27.1 (#1119)
OchiengEd Jun 27, 2023
ffc69d7
Correct spelling typo in CSVAnormalOver30Min alert desc (#2972)
mrbarge Jun 28, 2023
0e2fcc0
Adds codecov integration (#285)
m1kola Jun 29, 2023
d44340b
Avoid making the termination log executable (#1110)
ramikg Jun 30, 2023
a6b7309
Retry initialization error conditions (#2979)
tmshort Jul 5, 2023
c79bf2b
OWNERS: Remove timflannagan as a reviewer (#1123)
timflannagan Jul 6, 2023
0ac7ff9
Catalog source affinity (#2963)
Jamstah Jul 7, 2023
e1e17d5
Update golangci-lint to 1.51.1
tmshort Jul 12, 2023
e75731a
Update to go 1.20
tmshort Jul 11, 2023
ea6a854
Update dependencies
tmshort Jul 11, 2023
896f14b
Address golangci-lint comments
Jul 13, 2023
292dea1
Update to operator-registry v1.27.1
tmshort Jul 11, 2023
9926db8
Update packagemanifest
tmshort Jul 12, 2023
fddca7e
Run make verify
tmshort Jul 11, 2023
c2bf564
Update kind to v0.20.0
tmshort Jul 11, 2023
cc12ca1
Add architecture tolerations to bundleUnpacker job (#2958)
JamesMBartlett Jul 14, 2023
b2f4130
Update kubectl and helm (#2993)
tmshort Jul 17, 2023
dabe55f
OPRUN-2913: Update Dockerfiles to golang 1.20/ocp 4.14
tmshort Jul 17, 2023
ec11e29
OPRUN-2913: Update package-server-manager
tmshort Jul 17, 2023
045a139
Return lower-case string from GetSingularName() (#2997)
tmshort Jul 19, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 1 addition & 1 deletion base.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Dockerfile to bootstrap build and test in openshift-ci

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.18-openshift-4.11
FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.20-openshift-4.14

ARG KUBEBUILDER_RELEASE=2.3.1
# Install test dependencies
Expand Down
7 changes: 4 additions & 3 deletions cmd/package-server-manager/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import (

ctrl "sigs.k8s.io/controller-runtime"
"sigs.k8s.io/controller-runtime/pkg/cache"
"sigs.k8s.io/controller-runtime/pkg/client"
"sigs.k8s.io/controller-runtime/pkg/healthz"
"sigs.k8s.io/controller-runtime/pkg/log/zap"
"sigs.k8s.io/controller-runtime/pkg/manager"
Expand Down Expand Up @@ -75,13 +76,13 @@ func run(cmd *cobra.Command, args []string) error {
RenewDeadline: &le.RenewDeadline.Duration,
RetryPeriod: &le.RetryPeriod.Duration,
HealthProbeBindAddress: healthCheckAddr,
NewCache: cache.BuilderWithOptions(cache.Options{
SelectorsByObject: cache.SelectorsByObject{
Cache: cache.Options{
ByObject: map[client.Object]cache.ByObject{
&olmv1alpha1.ClusterServiceVersion{}: {
Field: packageserverCSVFields.AsSelector(),
},
},
}),
},
})
if err != nil {
setupLog.Error(err, "failed to setup manager instance")
Expand Down
283 changes: 131 additions & 152 deletions go.mod

Large diffs are not rendered by default.

1,158 changes: 331 additions & 827 deletions go.sum

Large diffs are not rendered by default.

464 changes: 464 additions & 0 deletions manifests/0000_50_olm_00-catalogsources.crd.yaml

Large diffs are not rendered by default.

259 changes: 218 additions & 41 deletions manifests/0000_50_olm_00-clusterserviceversions.crd.yaml

Large diffs are not rendered by default.

43 changes: 38 additions & 5 deletions manifests/0000_50_olm_00-subscriptions.crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -645,6 +645,21 @@ spec:
description: 'Resources represents compute resources required by this container. Immutable. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/'
type: object
properties:
claims:
description: "Claims lists the names of resources, defined in spec.resourceClaims, that are used by this container. \n This is an alpha field and requires enabling the DynamicResourceAllocation feature gate. \n This field is immutable. It can only be set for containers."
type: array
items:
description: ResourceClaim references one entry in PodSpec.ResourceClaims.
type: object
required:
- name
properties:
name:
description: Name must match the name of one entry in pod.spec.resourceClaims of the Pod where this field is used. It makes that resource available inside a container.
type: string
x-kubernetes-list-map-keys:
- name
x-kubernetes-list-type: map
limits:
description: 'Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
Expand All @@ -655,7 +670,7 @@ spec:
- type: string
x-kubernetes-int-or-string: true
requests:
description: 'Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
description: 'Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. Requests cannot exceed Limits. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
additionalProperties:
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
Expand Down Expand Up @@ -989,7 +1004,7 @@ spec:
description: 'medium represents what type of storage medium should back this directory. The default is "" which means to use the node''s default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir'
type: string
sizeLimit:
description: 'sizeLimit is the total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir'
description: 'sizeLimit is the total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir'
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
anyOf:
- type: integer
Expand Down Expand Up @@ -1018,7 +1033,7 @@ spec:
items:
type: string
dataSource:
description: 'dataSource field can be used to specify either: * An existing VolumeSnapshot object (snapshot.storage.k8s.io/VolumeSnapshot) * An existing PVC (PersistentVolumeClaim) If the provisioner or an external controller can support the specified data source, it will create a new volume based on the contents of the specified data source. If the AnyVolumeDataSource feature gate is enabled, this field will always have the same contents as the DataSourceRef field.'
description: 'dataSource field can be used to specify either: * An existing VolumeSnapshot object (snapshot.storage.k8s.io/VolumeSnapshot) * An existing PVC (PersistentVolumeClaim) If the provisioner or an external controller can support the specified data source, it will create a new volume based on the contents of the specified data source. When the AnyVolumeDataSource feature gate is enabled, dataSource contents will be copied to dataSourceRef, and dataSourceRef contents will be copied to dataSource when dataSourceRef.namespace is not specified. If the namespace is specified, then dataSourceRef will not be copied to dataSource.'
type: object
required:
- kind
Expand All @@ -1034,7 +1049,7 @@ spec:
description: Name is the name of resource being referenced
type: string
dataSourceRef:
description: 'dataSourceRef specifies the object from which to populate the volume with data, if a non-empty volume is desired. This may be any local object from a non-empty API group (non core object) or a PersistentVolumeClaim object. When this field is specified, volume binding will only succeed if the type of the specified object matches some installed volume populator or dynamic provisioner. This field will replace the functionality of the DataSource field and as such if both fields are non-empty, they must have the same value. For backwards compatibility, both fields (DataSource and DataSourceRef) will be set to the same value automatically if one of them is empty and the other is non-empty. There are two important differences between DataSource and DataSourceRef: * While DataSource only allows two specific types of objects, DataSourceRef allows any non-core object, as well as PersistentVolumeClaim objects. * While DataSource ignores disallowed values (dropping them), DataSourceRef preserves all values, and generates an error if a disallowed value is specified. (Beta) Using this field requires the AnyVolumeDataSource feature gate to be enabled.'
description: 'dataSourceRef specifies the object from which to populate the volume with data, if a non-empty volume is desired. This may be any object from a non-empty API group (non core object) or a PersistentVolumeClaim object. When this field is specified, volume binding will only succeed if the type of the specified object matches some installed volume populator or dynamic provisioner. This field will replace the functionality of the dataSource field and as such if both fields are non-empty, they must have the same value. For backwards compatibility, when namespace isn''t specified in dataSourceRef, both fields (dataSource and dataSourceRef) will be set to the same value automatically if one of them is empty and the other is non-empty. When namespace is specified in dataSourceRef, dataSource isn''t set to the same value and must be empty. There are three important differences between dataSource and dataSourceRef: * While dataSource only allows two specific types of objects, dataSourceRef allows any non-core object, as well as PersistentVolumeClaim objects. * While dataSource ignores disallowed values (dropping them), dataSourceRef preserves all values, and generates an error if a disallowed value is specified. * While dataSource only allows local objects, dataSourceRef allows objects in any namespaces. (Beta) Using this field requires the AnyVolumeDataSource feature gate to be enabled. (Alpha) Using the namespace field of dataSourceRef requires the CrossNamespaceVolumeDataSource feature gate to be enabled.'
type: object
required:
- kind
Expand All @@ -1049,10 +1064,28 @@ spec:
name:
description: Name is the name of resource being referenced
type: string
namespace:
description: Namespace is the namespace of resource being referenced Note that when a namespace is specified, a gateway.networking.k8s.io/ReferenceGrant object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferenceGrant documentation for details. (Alpha) This field requires the CrossNamespaceVolumeDataSource feature gate to be enabled.
type: string
resources:
description: 'resources represents the minimum resources the volume should have. If RecoverVolumeExpansionFailure feature is enabled users are allowed to specify resource requirements that are lower than previous value but must still be higher than capacity recorded in the status field of the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources'
type: object
properties:
claims:
description: "Claims lists the names of resources, defined in spec.resourceClaims, that are used by this container. \n This is an alpha field and requires enabling the DynamicResourceAllocation feature gate. \n This field is immutable. It can only be set for containers."
type: array
items:
description: ResourceClaim references one entry in PodSpec.ResourceClaims.
type: object
required:
- name
properties:
name:
description: Name must match the name of one entry in pod.spec.resourceClaims of the Pod where this field is used. It makes that resource available inside a container.
type: string
x-kubernetes-list-map-keys:
- name
x-kubernetes-list-type: map
limits:
description: 'Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
Expand All @@ -1063,7 +1096,7 @@ spec:
- type: string
x-kubernetes-int-or-string: true
requests:
description: 'Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
description: 'Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. Requests cannot exceed Limits. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
additionalProperties:
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
Expand Down
1 change: 0 additions & 1 deletion manifests/0000_90_olm_00-service-monitor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ metadata:
include.release.openshift.io/ibm-cloud-managed: "true"
include.release.openshift.io/self-managed-high-availability: "true"
spec:
jobLabel: k8s-app
endpoints:
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
interval: 30s
Expand Down
2 changes: 1 addition & 1 deletion manifests/0000_90_olm_01-prometheus-rule.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ spec:
namespace: "{{ $labels.namespace }}"
annotations:
summary: CSV abnormal for over 30 minutes
description: Fires whenever a CSV is in the Replacing, Pending, Deleting, or Unkown phase for more than 30 minutes.
description: Fires whenever a CSV is in the Replacing, Pending, Deleting, or Unknown phase for more than 30 minutes.
message: Failed to install Operator {{ $labels.name }} version {{ $labels.version }}. Phase-{{ $labels.phase }} Reason-{{ $labels.reason }}
- name: olm.installplan.rules
rules:
Expand Down
5 changes: 2 additions & 3 deletions pkg/package-server-manager/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ import (
"sigs.k8s.io/controller-runtime/pkg/controller/controllerutil"
"sigs.k8s.io/controller-runtime/pkg/handler"
"sigs.k8s.io/controller-runtime/pkg/reconcile"
"sigs.k8s.io/controller-runtime/pkg/source"
)

const (
Expand Down Expand Up @@ -113,7 +112,7 @@ func reconcileCSV(log logr.Logger, image string, csv *olmv1alpha1.ClusterService
return nil
}

func (r *PackageServerCSVReconciler) infrastructureHandler(obj client.Object) []reconcile.Request {
func (r *PackageServerCSVReconciler) infrastructureHandler(_ context.Context, obj client.Object) []reconcile.Request {
log := r.Log.WithValues("infrastructure", obj.GetName())
if obj.GetName() != infrastructureName {
log.Info("not processing events for the non-cluster infrastructure resource")
Expand All @@ -135,6 +134,6 @@ func (r *PackageServerCSVReconciler) infrastructureHandler(obj client.Object) []
func (r *PackageServerCSVReconciler) SetupWithManager(mgr ctrl.Manager) error {
return ctrl.NewControllerManagedBy(mgr).
For(&olmv1alpha1.ClusterServiceVersion{}).
Watches(&source.Kind{Type: &configv1.Infrastructure{}}, handler.EnqueueRequestsFromMapFunc(r.infrastructureHandler)).
Watches(&configv1.Infrastructure{}, handler.EnqueueRequestsFromMapFunc(r.infrastructureHandler)).
Complete(r)
}
8 changes: 5 additions & 3 deletions scripts/sync.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,15 @@ candidates() {
for remote in "${UPSTREAM_REMOTES[@]}"; do
"${ROOT_DIR}"/scripts/sync_get_candidates.sh "$remote"
done

# Create uber cherry-pick list
cat *.cherrypick | sort > all.cherrypick
echo "Number of commits to cherrypick: $(cat all.cherrypick | wc -l)"
}

pop() {
echo "Applying all upstream commit candidates"
for remote in "${UPSTREAM_REMOTES[@]}"; do
"${ROOT_DIR}"/scripts/sync_pop_candidate.sh -a "${remote}"
done
"${ROOT_DIR}"/scripts/sync_pop_candidate.sh -a "all"
}

check_local_branch_commit_diff() {
Expand Down
2 changes: 1 addition & 1 deletion scripts/sync_get_candidates.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ cherrypick_set="${remote}.cherrypick"
: > "${cherrypick_set}" # clear existing file
for rc in "${remote_commits[@]}"; do
if [[ -z $(git log -n 1 --no-merges --grep "${rc}" HEAD) && -z $(grep "${rc}" "${remote}.blacklist") ]]; then
printf '%s\n' "${rc}" >> "${cherrypick_set}"
git show -s --format="%cI ${remote} %H" "${rc}" >> "${cherrypick_set}"
(( ++picked ))
fi
done
Expand Down
Loading