Replies: 3 comments 6 replies
-
|
Looks like |
Beta Was this translation helpful? Give feedback.
-
|
Here is what I did in the exact order, I've tried this several times already: kubectl describe crd imagerepositories.image.toolkit.fluxcd.ioName: imagerepositories.image.toolkit.fluxcd.io
Namespace:
Labels: app.kubernetes.io/component=image-reflector-controller
app.kubernetes.io/instance=flux-system
app.kubernetes.io/part-of=flux
app.kubernetes.io/version=v0.38.3
kustomize.toolkit.fluxcd.io/name=flux-system
kustomize.toolkit.fluxcd.io/namespace=flux-system
Annotations: controller-gen.kubebuilder.io/version: v0.8.0
API Version: apiextensions.k8s.io/v1
Kind: CustomResourceDefinition
Metadata:
Creation Timestamp: 2023-01-23T09:44:29Z
Deletion Timestamp: 2023-01-25T10:44:39Z
Finalizers:
customresourcecleanup.apiextensions.k8s.io
Generation: 1
Managed Fields:
API Version: apiextensions.k8s.io/v1
Fields Type: FieldsV1
fieldsV1:
f:metadata:
f:annotations:
f:controller-gen.kubebuilder.io/version:
f:labels:
f:app.kubernetes.io/component:
f:app.kubernetes.io/instance:
f:app.kubernetes.io/part-of:
f:app.kubernetes.io/version:
f:spec:
f:group:
f:names:
f:kind:
f:listKind:
f:plural:
f:singular:
f:scope:
f:versions:
Manager: flux
Operation: Apply
Time: 2023-01-23T09:44:29Z
API Version: apiextensions.k8s.io/v1
Fields Type: FieldsV1
fieldsV1:
f:metadata:
f:annotations:
f:controller-gen.kubebuilder.io/version:
f:labels:
f:app.kubernetes.io/component:
f:app.kubernetes.io/instance:
f:app.kubernetes.io/part-of:
f:app.kubernetes.io/version:
f:kustomize.toolkit.fluxcd.io/name:
f:kustomize.toolkit.fluxcd.io/namespace:
f:spec:
f:group:
f:names:
f:kind:
f:listKind:
f:plural:
f:singular:
f:scope:
f:versions:
Manager: kustomize-controller
Operation: Apply
Time: 2023-01-23T09:44:38Z
API Version: apiextensions.k8s.io/v1
Fields Type: FieldsV1
fieldsV1:
f:status:
f:acceptedNames:
f:kind:
f:listKind:
f:plural:
f:singular:
f:conditions:
k:{"type":"Established"}:
.:
f:lastTransitionTime:
f:message:
f:reason:
f:status:
f:type:
k:{"type":"NamesAccepted"}:
.:
f:lastTransitionTime:
f:message:
f:reason:
f:status:
f:type:
k:{"type":"Terminating"}:
f:message:
f:reason:
Manager: kube-apiserver
Operation: Update
Subresource: status
Time: 2023-01-25T10:44:39Z
Resource Version: 495752129
UID: 84d6c61d-e989-475a-b376-10e9244f532b
Spec:
Conversion:
Strategy: None
Group: image.toolkit.fluxcd.io
Names:
Kind: ImageRepository
List Kind: ImageRepositoryList
Plural: imagerepositories
Singular: imagerepository
Scope: Namespaced
Versions:
Additional Printer Columns:
Json Path: .status.lastScanResult.scanTime
Name: Last scan
Type: string
Json Path: .status.lastScanResult.tagCount
Name: Tags
Type: string
Name: v1beta1
Schema:
openAPIV3Schema:
Description: ImageRepository is the Schema for the imagerepositories API
Properties:
API Version:
Description: APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
Type: string
Kind:
Description: Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Type: string
Metadata:
Type: object
Spec:
Description: ImageRepositorySpec defines the parameters for scanning an image repository, e.g., `fluxcd/flux`.
Properties:
Access From:
Description: AccessFrom defines an ACL for allowing cross-namespace references to the ImageRepository object based on the caller's namespace labels.
Properties:
Namespace Selectors:
Description: NamespaceSelectors is the list of namespace selectors to which this ACL applies. Items in this list are evaluated using a logical OR operation.
Items:
Description: NamespaceSelector selects the namespaces to which this ACL applies. An empty map of MatchLabels matches all namespaces in a cluster.
Properties:
Match Labels:
Additional Properties:
Type: string
Description: MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed.
Type: object
Type: object
Type: array
Required:
namespaceSelectors
Type: object
Cert Secret Ref:
Description: CertSecretRef can be given the name of a secret containing either or both of
- a PEM-encoded client certificate (`certFile`) and private key (`keyFile`); - a PEM-encoded CA certificate (`caFile`)
and whichever are supplied, will be used for connecting to the registry. The client cert and key are useful if you are authenticating with a certificate; the CA cert is useful if you are using a self-signed server certificate.
Properties:
Name:
Description: Name of the referent.
Type: string
Required:
name
Type: object
Exclusion List:
Description: ExclusionList is a list of regex strings used to exclude certain tags from being stored in the database.
Items:
Type: string
Type: array
Image:
Description: Image is the name of the image repository
Type: string
Interval:
Description: Interval is the length of time to wait between scans of the image repository.
Pattern: ^([0-9]+(\.[0-9]+)?(ms|s|m|h))+$
Type: string
Secret Ref:
Description: SecretRef can be given the name of a secret containing credentials to use for the image registry. The secret should be created with `kubectl create secret docker-registry`, or the equivalent.
Properties:
Name:
Description: Name of the referent.
Type: string
Required:
name
Type: object
Service Account Name:
Description: ServiceAccountName is the name of the Kubernetes ServiceAccount used to authenticate the image pull if the service account has attached pull secrets.
Max Length: 253
Type: string
Suspend:
Description: This flag tells the controller to suspend subsequent image scans. It does not apply to already started scans. Defaults to false.
Type: boolean
Timeout:
Description: Timeout for image scanning. Defaults to 'Interval' duration.
Pattern: ^([0-9]+(\.[0-9]+)?(ms|s|m))+$
Type: string
Type: object
Status:
Default:
Observed Generation: -1
Description: ImageRepositoryStatus defines the observed state of ImageRepository
Properties:
Canonical Image Name:
Description: CanonicalName is the name of the image repository with all the implied bits made explicit; e.g., `docker.io/library/alpine` rather than `alpine`.
Type: string
Conditions:
Items:
Description: Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example,
type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: "Available", "Progressing", and "Degraded" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"`
// other fields }
Properties:
Last Transition Time:
Description: lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
Format: date-time
Type: string
Message:
Description: message is a human readable message indicating details about the transition. This may be an empty string.
Max Length: 32768
Type: string
Observed Generation:
Description: observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.
Format: int64
Minimum: 0
Type: integer
Reason:
Description: reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.
Max Length: 1024
Min Length: 1
Pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
Type: string
Status:
Description: status of the condition, one of True, False, Unknown.
Enum:
True
False
Unknown
Type: string
Type:
Description: type of condition in CamelCase or in foo.example.com/CamelCase. --- Many .condition.type values are consistent across resources like Available, but because arbitrary conditions can be useful (see .node.status.conditions), the ability to deconflict is important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)
Max Length: 316
Pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
Type: string
Required:
lastTransitionTime
message
reason
status
type
Type: object
Type: array
Last Handled Reconcile At:
Description: LastHandledReconcileAt holds the value of the most recent reconcile request value, so a change of the annotation value can be detected.
Type: string
Last Scan Result:
Description: LastScanResult contains the number of fetched tags.
Properties:
Scan Time:
Format: date-time
Type: string
Tag Count:
Type: integer
Required:
tagCount
Type: object
Observed Generation:
Description: ObservedGeneration is the last reconciled generation.
Format: int64
Type: integer
Type: object
Type: object
Served: true
Storage: true
Subresources:
Status:
Status:
Accepted Names:
Kind: ImageRepository
List Kind: ImageRepositoryList
Plural: imagerepositories
Singular: imagerepository
Conditions:
Last Transition Time: 2023-01-23T09:44:29Z
Message: no conflicts found
Reason: NoConflicts
Status: True
Type: NamesAccepted
Last Transition Time: 2023-01-23T09:44:29Z
Message: the initial names have been accepted
Reason: InitialNamesAccepted
Status: True
Type: Established
Last Transition Time: 2023-01-25T10:44:39Z
Message: could not list instances: request to convert CR from an invalid group/version: image.toolkit.fluxcd.io/v1alpha1
Reason: InstanceDeletionFailed
Status: True
Type: Terminating
Stored Versions:
v1beta1
Events: <none>kubectl describe crd imageupdateautomations.image.toolkit.fluxcd.ioName: imageupdateautomations.image.toolkit.fluxcd.io
Namespace:
Labels: app.kubernetes.io/component=image-automation-controller
app.kubernetes.io/instance=flux-system
app.kubernetes.io/part-of=flux
app.kubernetes.io/version=v0.38.3
kustomize.toolkit.fluxcd.io/name=flux-system
kustomize.toolkit.fluxcd.io/namespace=flux-system
Annotations: controller-gen.kubebuilder.io/version: v0.8.0
API Version: apiextensions.k8s.io/v1
Kind: CustomResourceDefinition
Metadata:
Creation Timestamp: 2023-01-23T09:44:29Z
Deletion Timestamp: 2023-01-25T10:44:40Z
Finalizers:
customresourcecleanup.apiextensions.k8s.io
Generation: 1
Managed Fields:
API Version: apiextensions.k8s.io/v1
Fields Type: FieldsV1
fieldsV1:
f:metadata:
f:annotations:
f:controller-gen.kubebuilder.io/version:
f:labels:
f:app.kubernetes.io/component:
f:app.kubernetes.io/instance:
f:app.kubernetes.io/part-of:
f:app.kubernetes.io/version:
f:spec:
f:group:
f:names:
f:kind:
f:listKind:
f:plural:
f:singular:
f:scope:
f:versions:
Manager: flux
Operation: Apply
Time: 2023-01-23T09:44:29Z
API Version: apiextensions.k8s.io/v1
Fields Type: FieldsV1
fieldsV1:
f:metadata:
f:annotations:
f:controller-gen.kubebuilder.io/version:
f:labels:
f:app.kubernetes.io/component:
f:app.kubernetes.io/instance:
f:app.kubernetes.io/part-of:
f:app.kubernetes.io/version:
f:kustomize.toolkit.fluxcd.io/name:
f:kustomize.toolkit.fluxcd.io/namespace:
f:spec:
f:group:
f:names:
f:kind:
f:listKind:
f:plural:
f:singular:
f:scope:
f:versions:
Manager: kustomize-controller
Operation: Apply
Time: 2023-01-23T09:44:38Z
API Version: apiextensions.k8s.io/v1
Fields Type: FieldsV1
fieldsV1:
f:status:
f:acceptedNames:
f:kind:
f:listKind:
f:plural:
f:singular:
f:conditions:
k:{"type":"Established"}:
.:
f:lastTransitionTime:
f:message:
f:reason:
f:status:
f:type:
k:{"type":"NamesAccepted"}:
.:
f:lastTransitionTime:
f:message:
f:reason:
f:status:
f:type:
k:{"type":"Terminating"}:
f:message:
f:reason:
Manager: kube-apiserver
Operation: Update
Subresource: status
Time: 2023-01-25T10:44:40Z
Resource Version: 495752850
UID: c03bb82f-a721-4337-9fae-c8f26a150f7f
Spec:
Conversion:
Strategy: None
Group: image.toolkit.fluxcd.io
Names:
Kind: ImageUpdateAutomation
List Kind: ImageUpdateAutomationList
Plural: imageupdateautomations
Singular: imageupdateautomation
Scope: Namespaced
Versions:
Additional Printer Columns:
Json Path: .status.lastAutomationRunTime
Name: Last run
Type: string
Name: v1beta1
Schema:
openAPIV3Schema:
Description: ImageUpdateAutomation is the Schema for the imageupdateautomations API
Properties:
API Version:
Description: APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
Type: string
Kind:
Description: Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Type: string
Metadata:
Type: object
Spec:
Description: ImageUpdateAutomationSpec defines the desired state of ImageUpdateAutomation
Properties:
Git:
Description: GitSpec contains all the git-specific definitions. This is technically optional, but in practice mandatory until there are other kinds of source allowed.
Properties:
Checkout:
Description: Checkout gives the parameters for cloning the git repository, ready to make changes. If not present, the `spec.ref` field from the referenced `GitRepository` or its default will be used.
Properties:
Ref:
Description: Reference gives a branch, tag or commit to clone from the Git repository.
Properties:
Branch:
Description: Branch to check out, defaults to 'master' if no other field is defined.
When GitRepositorySpec.GitImplementation is set to 'go-git', a shallow clone of the specified branch is performed.
Type: string
Commit:
Description: Commit SHA to check out, takes precedence over all reference fields.
When GitRepositorySpec.GitImplementation is set to 'go-git', this can be combined with Branch to shallow clone the branch, in which the commit is expected to exist.
Type: string
Semver:
Description: SemVer tag expression to check out, takes precedence over Tag.
Type: string
Tag:
Description: Tag to check out, takes precedence over Branch.
Type: string
Type: object
Required:
ref
Type: object
Commit:
Description: Commit specifies how to commit to the git repository.
Properties:
Author:
Description: Author gives the email and optionally the name to use as the author of commits.
Properties:
Email:
Description: Email gives the email to provide when making a commit.
Type: string
Name:
Description: Name gives the name to provide when making a commit.
Type: string
Required:
email
Type: object
Message Template:
Description: MessageTemplate provides a template for the commit message, into which will be interpolated the details of the change made.
Type: string
Signing Key:
Description: SigningKey provides the option to sign commits with a GPG key
Properties:
Secret Ref:
Description: SecretRef holds the name to a secret that contains a 'git.asc' key corresponding to the ASCII Armored file containing the GPG signing keypair as the value. It must be in the same namespace as the ImageUpdateAutomation.
Properties:
Name:
Description: Name of the referent.
Type: string
Required:
name
Type: object
Type: object
Required:
author
Type: object
Push:
Description: Push specifies how and where to push commits made by the automation. If missing, commits are pushed (back) to `.spec.checkout.branch` or its default.
Properties:
Branch:
Description: Branch specifies that commits should be pushed to the branch named. The branch is created using `.spec.checkout.branch` as the starting point, if it doesn't already exist.
Type: string
Required:
branch
Type: object
Required:
commit
Type: object
Interval:
Description: Interval gives an lower bound for how often the automation run should be attempted.
Pattern: ^([0-9]+(\.[0-9]+)?(ms|s|m|h))+$
Type: string
Source Ref:
Description: SourceRef refers to the resource giving access details to a git repository.
Properties:
API Version:
Description: API version of the referent.
Type: string
Kind:
Default: GitRepository
Description: Kind of the referent.
Enum:
GitRepository
Type: string
Name:
Description: Name of the referent.
Type: string
Namespace:
Description: Namespace of the referent, defaults to the namespace of the Kubernetes resource object that contains the reference.
Type: string
Required:
kind
name
Type: object
Suspend:
Description: Suspend tells the controller to not run this automation, until it is unset (or set to false). Defaults to false.
Type: boolean
Update:
Default:
Strategy: Setters
Description: Update gives the specification for how to update the files in the repository. This can be left empty, to use the default value.
Properties:
Path:
Description: Path to the directory containing the manifests to be updated. Defaults to 'None', which translates to the root path of the GitRepositoryRef.
Type: string
Strategy:
Default: Setters
Description: Strategy names the strategy to be used.
Enum:
Setters
Type: string
Required:
strategy
Type: object
Required:
interval
sourceRef
Type: object
Status:
Default:
Observed Generation: -1
Description: ImageUpdateAutomationStatus defines the observed state of ImageUpdateAutomation
Properties:
Conditions:
Items:
Description: Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example,
type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: "Available", "Progressing", and "Degraded" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"`
// other fields }
Properties:
Last Transition Time:
Description: lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
Format: date-time
Type: string
Message:
Description: message is a human readable message indicating details about the transition. This may be an empty string.
Max Length: 32768
Type: string
Observed Generation:
Description: observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.
Format: int64
Minimum: 0
Type: integer
Reason:
Description: reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.
Max Length: 1024
Min Length: 1
Pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
Type: string
Status:
Description: status of the condition, one of True, False, Unknown.
Enum:
True
False
Unknown
Type: string
Type:
Description: type of condition in CamelCase or in foo.example.com/CamelCase. --- Many .condition.type values are consistent across resources like Available, but because arbitrary conditions can be useful (see .node.status.conditions), the ability to deconflict is important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)
Max Length: 316
Pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
Type: string
Required:
lastTransitionTime
message
reason
status
type
Type: object
Type: array
Last Automation Run Time:
Description: LastAutomationRunTime records the last time the controller ran this automation through to completion (even if no updates were made).
Format: date-time
Type: string
Last Handled Reconcile At:
Description: LastHandledReconcileAt holds the value of the most recent reconcile request value, so a change of the annotation value can be detected.
Type: string
Last Push Commit:
Description: LastPushCommit records the SHA1 of the last commit made by the controller, for this automation object
Type: string
Last Push Time:
Description: LastPushTime records the time of the last pushed change.
Format: date-time
Type: string
Observed Generation:
Format: int64
Type: integer
Type: object
Type: object
Served: true
Storage: true
Subresources:
Status:
Status:
Accepted Names:
Kind: ImageUpdateAutomation
List Kind: ImageUpdateAutomationList
Plural: imageupdateautomations
Singular: imageupdateautomation
Conditions:
Last Transition Time: 2023-01-23T09:44:29Z
Message: no conflicts found
Reason: NoConflicts
Status: True
Type: NamesAccepted
Last Transition Time: 2023-01-23T09:44:29Z
Message: the initial names have been accepted
Reason: InitialNamesAccepted
Status: True
Type: Established
Last Transition Time: 2023-01-25T10:44:40Z
Message: could not list instances: request to convert CR from an invalid group/version: image.toolkit.fluxcd.io/v1alpha1
Reason: InstanceDeletionFailed
Status: True
Type: Terminating
Stored Versions:
v1beta1
Events: <none>** Then I removed finalizers from the remaining CRD's ** Now all Fluxcd CRDS appear to be gone, flux-system namespace is deleted as well. Flux bootstrap Now after I've successfully bootstrapped the cluster, the issue persists: I've tried uninstalling, patching deadlocked CRD finalizers & bootstraping several times with no success. |
Beta Was this translation helpful? Give feedback.
-
|
Issues like this may be related to stale managedFields.
We know that this is working well for beta API's but if you are moving from alpha API's and try |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to update Flux to the latest version.
Here is what I did:
flux uninstall --namespace=flux=systemto remove flux components & CRDS.v1alpha1tov1beta1Now when I run
flux bootstrap&flux check, it reports that everything is healthy.However, the kustomize controller throws this error: request to convert CR from an invalid group/version: image.toolkit.fluxcd.io/v1alpha1
All resources in the git repo have been migrated, there are no resources with
v1alpha1anymore.How do I troubleshoot this?
Beta Was this translation helpful? Give feedback.
All reactions