Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

Have riff install process check target k8s version #52

Open
georgeharley opened this issue Oct 31, 2018 · 2 comments
Open

Have riff install process check target k8s version #52

georgeharley opened this issue Oct 31, 2018 · 2 comments

Comments

@georgeharley
Copy link

At present, running riff system install against a Kubernetes cluster that fails to meet the minimum version requirement of knative will appear to succeed but later on problems can occur when running other commands such as riff function create. It could be a big time saver if riff system install could detect that the target cluster did not meet the minimum k8s version requirement and so fail early.

@georgeharley
Copy link
Author

As a bit of background on why this issue has been created:
I installed riff on a GKE cluster that had previously been created using the web console where the Kubernetes version had defaulted to 1.9.7. Running riff system install seemed to complete OK but when riff function create node square ... was run (as per the getting started guide for GKE) there was a failure message:

Error: function creation failed: RevisionMissing: Configuration "square" does not have any ready Revision.; Revision "square-00001" failed with message: "Unable to create pods for more than 120 seconds.".

Attempts to invoke the square function failed silently (a "HTTP 404 Not Found" could be seen when run verbosely though). The virtual service required to direct invocation request traffic to the function was also found not to exist (presumably because of the revision creation failure).

It was only after creating a new 1.10.7 GKE cluster and using that to install and run riff on that things worked as expected. Would be nice to catch that problem in riff system install so that it failed fast.

@fbiville
Copy link
Contributor

As far as I understand, we can get the current k8s version like this:

kubectl version --output json | jq -r '(.serverVersion.major + "." + .serverVersion.minor)'
1.11
kubectl version --output json | jq -r '.serverVersion.gitVersion'
v1.11.5

I'm not completely sure about getting the mininal version requirement from Knative. Would the version of the transitive dependency k8s.io/api be enough?

@scothis scothis transferred this issue from projectriff/riff Jun 20, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants